diff --git a/.gitignore b/.gitignore index 3c41f8c..853b65a 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,6 @@ -config.php .idea/ .vscode/ -.code/ \ No newline at end of file +.code/ +*.log +src/config.php +node_modules diff --git a/404.php b/404.php deleted file mode 100644 index 1f01ea7..0000000 --- a/404.php +++ /dev/null @@ -1,17 +0,0 @@ - -
-

-

-
-render_incidents(false,$_GET['offset'],5); - exit(); -}else if (isset($_GET['offset'])) -{ - $offset = $_GET['offset']; -} - -if (isset($_GET['new']) && $_GET['new']=="incident") -{ - Incident::add(); -} - -if (isset($_GET['delete'])) -{ - Incident::delete($_GET['delete']); -} -if (isset($_GET['tasks'])) { - Queue::process_queue(); -} - -Template::render_header(_("Dashboard"), true); -?> - -
-

-

get_name();?>

-
- -
- render_status(true); - ?> -
-
-
-
-
-

-
-
- -

- -
- -
-
get_status()!=-1){?>get_id(), $post_services))?"checked":'';?> id="service-get_id(); ?>">
-
get_status()!=-1){echo $statuses[$service->get_status()];}?>
-
- -
-
-
-
- -
-
- " value="" required> "> - - -
-
- -
- -
- - -
- render_incidents(true,$offset,5,true); - $constellation->render_incidents(false,$offset,5,true); - ?> -
-
-
diff --git a/admin/index.php b/admin/index.php deleted file mode 100644 index 345f89c..0000000 --- a/admin/index.php +++ /dev/null @@ -1,138 +0,0 @@ -getSetting($mysqli,"name")); - define("TITLE", $db->getSetting($mysqli,"title")); - define("WEB_URL", $db->getSetting($mysqli,"url")); - define("MAILER_NAME", $db->getSetting($mysqli,"mailer")); - define("MAILER_ADDRESS", $db->getSetting($mysqli,"mailer_email")); - - define("GOOGLE_RECAPTCHA", $db->getBooleanSetting($mysqli, "google_recaptcha")); - define("GOOGLE_RECAPTCHA_SECRET", $db->getSetting($mysqli, "google_recaptcha_secret")); - define("GOOGLE_RECAPTCHA_SITEKEY", $db->getSetting($mysqli, "google_recaptcha_sitekey")); - define("SUBSCRIBE_EMAIL", $db->getBooleanSetting($mysqli, "subscribe_email")); - define("SUBSCRIBE_TELEGRAM", $db->getBooleanSetting($mysqli, "subscribe_telegram")); - define("TG_BOT_USERNAME", $db->getSetting($mysqli, "tg_bot_username")); - define("TG_BOT_API_TOKEN", $db->getSetting($mysqli, "tg_bot_api_token")); - define("PHP_MAILER", $db->getBooleanSetting($mysqli, "php_mailer")); - define("PHP_MAILER_SMTP", $db->getBooleanSetting($mysqli, "php_mailer_smtp")); - define("PHP_MAILER_PATH", $db->getSetting($mysqli, "php_mailer_path")); - define("PHP_MAILER_HOST", $db->getSetting($mysqli, "php_mailer_host")); - define("PHP_MAILER_PORT", $db->getSetting($mysqli, "php_mailer_port")); - define("PHP_MAILER_SECURE", $db->getBooleanSetting($mysqli, "php_mailer_secure")); - define("PHP_MAILER_USER", $db->getSetting($mysqli, "php_mailer_user")); - define("PHP_MAILER_PASS", $db->getSetting($mysqli, "php_mailer_pass")); - define("CRON_SERVER_IP", $db->getSetting($mysqli, "cron_server_ip")); - - // Process the subscriber notification queue - // If CRON_SERVER_IP is not set, call notification once incident has been saved - if ( empty(CRON_SERVER_IP) ) - { - if ( isset($_GET['sent']) && $_GET['sent'] == true ) - { - Queue::process_queue(); - } - } - else if ( isset($_GET['task']) && $_GET['task'] == 'cron' ) - { - // Else, base it on call to /admin?task=cron being called from IP defined by CRON_SERVER_IP - if (! empty(CRON_SERVER_IP) && $_SERVER['REMOTE_ADDR'] == CRON_SERVER_IP ) - { - Queue::process_queue(); - syslog(1, "CRON server processed"); - } - else { - syslog(1, "CRON called from unauthorised server"); - } - } - - - if(isset($_COOKIE['user'])&&!isset($_SESSION['user'])) - { - User::restore_session(); - } - - if (!isset($_SESSION['user'])) - { - if (isset($_GET['do']) && $_GET['do']=="lost-password") - { - require_once("lost-password.php"); - }else if (isset($_GET['do']) && $_GET['do']=="change-email"){ - $user_pwd = new User($_GET['id']); - $user_pwd->change_email(); - require_once("login-form.php"); - } - else{ - User::login(); - require_once("login-form.php"); - } - } - else - { - $user = new User($_SESSION['user']); - if (!$user->is_active()) - { - User::logout(); - } - - if (!isset($_GET['do'])){ - $do = ""; - }else{ - $do = $_GET['do']; - } - - switch ($do) { - case 'change-email': - $user = new User($_GET['id']); - $user->change_email(); - case 'user': - require_once("user.php"); - break; - - case 'settings': - require_once("settings.php"); - break; - - case 'new-user': - require_once("new-user.php"); - break; - - case 'new-service': - case 'edit-service': - require_once('service.php'); - break; - - case 'new-service-group': - case 'edit-service-group': - require_once('service-group.php'); - break; - - case 'options': - require_once("options.php"); - break; - - case 'logout': - User::logout(); - break; - - default: - require_once("dashboard.php"); - break; - } - - Template::render_footer(true); - } -} diff --git a/admin/login-form.php b/admin/login-form.php deleted file mode 100644 index f4ef6f9..0000000 --- a/admin/login-form.php +++ /dev/null @@ -1,32 +0,0 @@ - -
-

-
-
- -

- -

- -
-
- - " class="form-control" name="email" id="email" type="email" tabindex="1" value="" required> -
-
- - " class="form-control" name="pass" id="pass" type="password" tabindex="2" required> -
- - -
-
-
- -
-
-
- -
-

Add new user

-
- -
- -

- -
-
" class="form-control" required>
-
" class="form-control" required>
-
-
-
" class="form-control" required>
-
" class="form-control" required>
-
-
-
" class="form-control" required>
-
- - -
-
- -
diff --git a/admin/options.php b/admin/options.php deleted file mode 100644 index 3ebdb16..0000000 --- a/admin/options.php +++ /dev/null @@ -1,183 +0,0 @@ -getBooleanSetting($mysqli, "notifyUpdates"); - $emailSubscription_status = $db->getBooleanSetting($mysqli, "subscribe_email"); - $telegramSubscription_status = $db->getBooleanSetting($mysqli, "subscribe_telegram"); - $tg_bot_api_token = $db->getSetting($mysqli, "tg_bot_api_token"); - $tg_bot_username = $db->getSetting($mysqli, "tg_bot_username"); - $php_mailer_status = $db->getBooleanSetting($mysqli, "php_mailer"); - $php_mailer_smtp_status = $db->getBooleanSetting($mysqli, "php_mailer_smtp"); - $php_mailer_secure_status = $db->getBooleanSetting($mysqli, "php_mailer_secure"); - $php_mailer_path = $db->getSetting($mysqli, "php_mailer_path"); - $php_mailer_host = $db->getSetting($mysqli, "php_mailer_host"); - $php_mailer_port = $db->getSetting($mysqli, "php_mailer_port"); - $php_mailer_user = $db->getSetting($mysqli, "php_mailer_user"); - $php_mailer_pass = $db->getSetting($mysqli, "php_mailer_pass"); - $cron_server_ip = $db->getSetting($mysqli, "cron_server_ip"); - $google_rechaptcha_status = $db->getBooleanSetting($mysqli, "google_recaptcha"); - $google_recaptcha_sitekey = $db->getSetting($mysqli, "google_recaptcha_sitekey"); - $google_recaptcha_secret = $db->getSetting($mysqli, "google_recaptcha_secret"); - - $db->getSetting($mysqli, ""); - $set_post = false; - if(!empty($_POST)){ - $db->updateSetting($mysqli, "notifyUpdates", getToggle($_POST["nu_toggle"])); - $db->updateSetting($mysqli, "name",htmlspecialchars($_POST["sitename"], ENT_QUOTES)); - $db->updateSetting($mysqli, "subscribe_email", getToggle($_POST["email_subscription_toggle"])); - $db->updateSetting($mysqli, "subscribe_telegram", getToggle($_POST["telegram_subscription_toggle"])); - $db->updateSetting($mysqli, "tg_bot_api_token", htmlspecialchars($_POST["tg_bot_api_token"], ENT_QUOTES)); - $db->updateSetting($mysqli, "tg_bot_username", htmlspecialchars($_POST["tg_bot_username"], ENT_QUOTES)); - $db->updateSetting($mysqli, "php_mailer", getToggle($_POST["php_mailer_toggle"])); - $db->updateSetting($mysqli, "php_mailer_smtp", getToggle($_POST["php_mailer_smtp_toggle"])); - $db->updateSetting($mysqli, "php_mailer_secure", getToggle($_POST["php_mailer_secure_toggle"])); - $db->updateSetting($mysqli, "php_mailer_path", htmlspecialchars($_POST["php_mailer_path"], ENT_QUOTES)); - $db->updateSetting($mysqli, "php_mailer_host", htmlspecialchars($_POST["php_mailer_host"], ENT_QUOTES)); - $db->updateSetting($mysqli, "php_mailer_port", htmlspecialchars($_POST["php_mailer_port"], ENT_QUOTES)); - $db->updateSetting($mysqli, "php_mailer_user", htmlspecialchars($_POST["php_mailer_user"], ENT_QUOTES)); - $db->updateSetting($mysqli, "php_mailer_pass", htmlspecialchars($_POST["php_mailer_pass"], ENT_QUOTES)); - $db->updateSetting($mysqli, "cron_server_ip", htmlspecialchars($_POST["cron_server_ip"], ENT_QUOTES)); - $db->updateSetting($mysqli, "google_recaptcha", getToggle($_POST["google_rechaptcha_toggle"])); - $db->updateSetting($mysqli, "google_recaptcha_sitekey", htmlspecialchars($_POST["google_recaptcha_sitekey"], ENT_QUOTES)); - $db->updateSetting($mysqli, "google_recaptcha_secret", htmlspecialchars($_POST["google_recaptcha_secret"], ENT_QUOTES)); - - $set_post = true; - /*if($nu_toggle == "yes"){ - $notifyUpdates_status = true; - } else { - $notifyUpdates_status = false; - }*/ - // TODO - Reload page to prevent showing old values! or update variables being displayed - header("Location: " .$uri = $_SERVER['REQUEST_URI']); - // TODO - The code below will not happen ... - - /*define("NAME", $db->getSetting($mysqli,"name")); - define("TITLE", $db->getSetting($mysqli,"title")); - define("WEB_URL", $db->getSetting($mysqli,"url")); - define("MAILER_NAME", $db->getSetting($mysqli,"mailer")); - define("MAILER_ADDRESS", $db->getSetting($mysqli,"mailer_email")); - define("SUBSCRIBER_EMAIL", $db->getSetting($mysqli,"subscriber_email")); - define("SUBSCRIBER_TELEGRAM", $db->getSetting($mysqli,"subscriber_telegram")); - define("TG_BOT_API_TOKEN", $db->getSetting($mysqli,"tg_bot_api_token")); - define("TG_BOT_USERNAME", $db->getSetting($mysqli,"tg_bot_username")); - define("GOOGLE_RECAPTCHA", $db->getSetting($mysqli,"google_recaptcha")); - define("GOOGLE_RECAPTCHA_SITEKEY", $db->getSetting($mysqli,"google_recaptcha_sitekey")); - define("GOOGLE_RECAPTCHA_SECRET", $db->getSetting($mysqli,"google_recaptcha_secret")); - define("PHP_MAILER", $db->getSetting($mysqli,"php_mailer")); - define("PHP_MAILER_PATH", $db->getSetting($mysqli,"php_mailer_path")); - define("PHP_MAILER_SMTP", $db->getSetting($mysqli,"php_mailer_smtp")); - define("PHP_MAILER_HOST", $db->getSetting($mysqli,"php_mailer_host")); - define("PHP_MAILER_PORT", $db->getSetting($mysqli,"php_mailer_port")); - define("PHP_MAILER_SECURE", $db->getSetting($mysqli,"php_mailer_secure")); - define("PHP_MAILER_USER", $db->getSetting($mysqli,"php_mailer_user")); - define("PHP_MAILER_PASS", $db->getSetting($mysqli,"php_mailer_pass")); - define("CRON_SERVER_IP", $db->getSetting($mysqli,"cron_server_ip")); - */ - } - Template::render_header(_("Options"), true); -?> -
-

-
-
- -
-
- Site Name -
- -
- - - - -
-
- Telegram BOT API Token -
- -
-
-
- Telegram BOT Username -
- -
- - - - -
-
- PHPMailer Path -
- -
-
-
- PHPMailer SMTP Host -
- -
-
-
- PHPMailer SMTP Port -
- -
-
-
- PHPMailer Username -
- -
-
-
- PHPMailer Password -
- -
-
-
- Cron Server IP -
- -
- - -
-
- Google reChaptcha Sitekey -
- -
-
-
- Google reChaptcha Secret -
- -
- - - - -
diff --git a/admin/service-group.php b/admin/service-group.php deleted file mode 100644 index 23f3293..0000000 --- a/admin/service-group.php +++ /dev/null @@ -1,99 +0,0 @@ -prepare("SELECT * FROM services_groups WHERE id LIKE ?"); - $stmt->bind_param("i", $group_id); - $stmt->execute(); - $query = $stmt->get_result(); - $data = $query->fetch_assoc(); - $group_value = $data['name']; - $description_value = $data['description']; - $visibility_id_value = $data['visibility']; -} - - -if (!$boolEdit) { - -Template::render_header(_("New service group"), true); ?> -
-

-
- -
-

-
- - -
- -

- -
-
" class="form-control" required>
-
" class="form-control">
-
-
-
- - -
-
- '; - } - ?> - -
diff --git a/admin/service.php b/admin/service.php deleted file mode 100644 index 1f51d70..0000000 --- a/admin/service.php +++ /dev/null @@ -1,97 +0,0 @@ -prepare("SELECT * FROM services WHERE id LIKE ?"); - $stmt->bind_param("i", $service_id); - $stmt->execute(); - $query = $stmt->get_result(); - $data = $query->fetch_assoc(); - //print_r($data); - $service_value = $data['name']; - $description_value = $data['description']; - $group_id_value = $data['group_id']; -} - - -if (!$boolEdit) { - -Template::render_header(_("New service"), true); ?> -
-

-
- -
-

-
- -
- -

- -
-
" class="form-control" required>
-
" class="form-control">
-
-
-
- - -
-
- '; - } - ?> - -
diff --git a/admin/settings.php b/admin/settings.php deleted file mode 100644 index bd93f10..0000000 --- a/admin/settings.php +++ /dev/null @@ -1,141 +0,0 @@ - -
-

Settings

-
- -

- -
-

- get_rank() <= 1){?> -
-
- -
-
- -
- - - - - - - - get_rank()<=1) - {?> - - - - - - query("SELECT services.*, services_groups.name AS group_name FROM `services` LEFT JOIN services_groups ON services.group_id = services_groups.id ORDER BY services.name ASC"); - while($result = $query->fetch_assoc()) - { - echo ""; - //echo ""; - echo '"; - echo ""; - - if ($user->get_rank()<=1) - { - echo ''; - } - echo ""; - }?> - -
".$result['id']."'.$result['name'].''; - echo "".$result['description']."".$result['group_name']."
-
-
- -
-

- get_rank() <= 1){?> -
-
- -
-
- -
- - - - - - - - - get_rank()<=1) - {?> - - - - - - query("SELECT sg.* , (SELECT COUNT(*) FROM services WHERE services.group_id = sg.id) AS counter FROM services_groups AS sg ORDER BY sg.id ASC"); - while($result = $query->fetch_assoc()) - { - echo ""; - //echo ""; - echo '"; - echo ""; - - if ($user->get_rank()<=1) - { - echo ''; - } - echo ""; - }?> - -
".$result['id']."'.$result['name'].''; - echo ' '.$result['counter'].''; - echo "".$result['description']."".$visibility[$result['visibility']]."
-
-
- - -
-

- get_rank() == 0){?> -
- - - - - query("SELECT * FROM users"); - while($result = $query->fetch_assoc()) - { - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - }?> - -
Active
".$result['id']."".$result['username']."".$result['name']."".$result['surname']."".$result['email']."".$permissions[$result['permission']].""; - echo ""; - echo "
-
-
diff --git a/admin/user.php b/admin/user.php deleted file mode 100644 index 04c7ca4..0000000 --- a/admin/user.php +++ /dev/null @@ -1,64 +0,0 @@ -change_password(); -} - -if (isset($_POST['username'])) -{ - $displayed_user->change_username(); -} - -if (isset($_POST['name'])) -{ - $displayed_user->change_name(); -} - -if (isset($_POST['email'])) -{ - $success = $displayed_user->email_link(); -} - -if (isset($_POST['permission'])) -{ - $displayed_user->change_permission(); -} - - -if (isset($_GET['what']) && $_GET['what']=='toggle') -{ - $displayed_user->toggle(); -} - -Template::render_header(_("User"), true); - -?> -
-

-
- -

- -

-render_user_settings(); \ No newline at end of file diff --git a/api/incidents.php b/api/incidents.php deleted file mode 100644 index 105509f..0000000 --- a/api/incidents.php +++ /dev/null @@ -1,19 +0,0 @@ -get_incidents((isset($_GET['future'])?$_GET['future']:false), $offset, $limit, $timestamp); - header('Cache-Control: no-cache'); - header('Content-type: application/json'); - echo json_encode($result); -} \ No newline at end of file diff --git a/api/status.php b/api/status.php deleted file mode 100644 index 5ace02d..0000000 --- a/api/status.php +++ /dev/null @@ -1,42 +0,0 @@ -render_status(true, false); - echo json_encode($array); - }else{ - $query = $mysqli->prepare("SELECT name FROM services WHERE id=?"); - $query->bind_param("i", $_GET['id']); - $query->execute(); - $result = $query->get_result()->fetch_assoc(); - if (!count($result)) - { - die(json_encode(["error" => _("Service does not exist!")])); - } - - $sql = $mysqli->prepare("SELECT type FROM services_status INNER JOIN status ON services_status.status_id = status.id WHERE service_id = ? AND `time` <= ? AND (`end_time` >= ? OR `end_time`=0) ORDER BY `time` DESC LIMIT 1"); - - $sql->bind_param("iii", $id, $timestamp, $timestamp); - $sql->execute(); - $tmp = $sql->get_result(); - if ($tmp->num_rows) - { - $service = new Service($_GET['id'], $result['name'], $tmp->fetch_assoc()['type']); - } - else{ - $service = new Service($_GET['id'], $result['name']); - } - - echo json_encode($service); - } -} \ No newline at end of file diff --git a/classes/constellation.php b/classes/constellation.php deleted file mode 100644 index f7ab8d0..0000000 --- a/classes/constellation.php +++ /dev/null @@ -1,213 +0,0 @@ -get_incidents($future, $offset, $limit, $timestamp); - - $ajax = isset($_GET['ajax']); - - if ($future && count($incidents["incidents"]) && !$ajax) - { - echo "

"._("Planned maintenance")."

"; - } - else if (count($incidents["incidents"]) &&!$ajax) - { - if ($offset) - { - echo ''; - } - echo "

"._("Past incidents")."

"; - } - else if (!$future &&!$ajax) - { - echo "

"._("No incidents")."

"; - } - $show = !$future && $incidents["more"]; - - $offset += $limit; - - if (count($incidents["incidents"])){ - foreach ($incidents['incidents'] as $incident) { - $incident->render($admin); - } - - if ($show) - { - echo '
'._("Load more").'
'; - } - } - } - - /** - * Renders service status - in admin page it returns array so it can be processed further. - * @param boolean $admin - * @return array of services - */ - public function render_status($admin = false, $heading = true){ - global $mysqli; - - //$query = $mysqli->query("SELECT id, name, description FROM services"); - $query = $mysqli->query("SELECT services.id, services.name, services.description, services_groups.name as group_name FROM services LEFT JOIN services_groups ON services.group_id=services_groups.id ORDER BY services_groups.name "); - $array = array(); - if ($query->num_rows){ - $timestamp = time(); - - while($result = $query->fetch_assoc()) - { - $id = $result['id']; - $sql = $mysqli->prepare("SELECT type FROM services_status INNER JOIN status ON services_status.status_id = status.id WHERE service_id = ? AND `time` <= ? AND (`end_time` >= ? OR `end_time`=0) ORDER BY `time` DESC LIMIT 1"); - - $sql->bind_param("iii", $id, $timestamp, $timestamp); - $sql->execute(); - $tmp = $sql->get_result(); - if ($tmp->num_rows) - { - $array[] = new Service($result['id'], $result['name'], $result['description'], $result['group_name'], $tmp->fetch_assoc()['type']); - } - else{ - $array[] = new Service($result['id'], $result['name'], $result['description'], $result['group_name']); - } - } - if ($heading) - { - echo Service::current_status($array); - } - } - else{ - $array[] = new Service(0, _("No services"), -1); - } - if (!$admin) - { - ?> - - '; - //$arrCompletedGroups = array(); - foreach($array as $service){ - //print_r($service); - //if ( !empty($service->group_name) && !in_array($service->group_name, $arrCompletedGroups)) { -//print $service->name; - // $arrCompletedGroups[] = $service['group_name']; - // $service->render(true); - //} else { - $service->render(); - //} - } - echo ''; - //echo ''; - } - else{ - return $array; - } - } - - - function get_incidents($future = false, $offset = 0, $limit = 5, $timestamp = 0){ - global $mysqli; - if ($timestamp == 0) - { - $timestamp = time(); - } - - $operator = ($future)?">=":"<="; - $limit++; - $sql = $mysqli->prepare("SELECT users.id, status.type, status.title, status.text, status.time, status.end_time, users.username, status.id as status_id FROM status INNER JOIN users ON user_id=users.id WHERE `time` $operator ? AND `end_time` $operator ? OR (`time`<=? AND `end_time` $operator ? ) ORDER BY `time` DESC LIMIT ? OFFSET ?"); - $sql->bind_param("iiiiii",$timestamp, $timestamp, $timestamp, $timestamp, $limit, $offset); - $sql->execute(); - $query = $sql->get_result(); - $array = []; - $limit--; - $more = false; - if ($query->num_rows>$limit){ - $more = true; - } - if ($query->num_rows){ - while(($result = $query->fetch_assoc()) && $limit-- > 0) - { - // Add service id and service names to an array in the Incident class - $stmt_service = $mysqli->prepare("SELECT services.id,services.name FROM services - INNER JOIN services_status ON services.id = services_status.service_id - WHERE services_status.status_id = ?"); - $stmt_service->bind_param("i", $result['status_id']); - $stmt_service->execute(); - $query_service = $stmt_service->get_result(); - while($result_service = $query_service->fetch_assoc()) { - $result['service_id'][] = $result_service['id']; - $result['service_name'][] = $result_service['name']; - } - - $array[] = new Incident($result); - } - } - return [ - "more" => $more, - "incidents" => $array - ]; - } - - - function render_warning($header, $message, $show_link = false, $url = null, $link_text = null) - { - $this->render_alert('alert-warning', $header, $message, $show_link, $url, $link_text); - } - function render_success($header, $message, $show_link = false, $url = null, $link_text = null) - { - $this->render_alert('alert-success', $header, $message, $show_link, $url, $link_text); - } - - /** - * Renders an alert on screen with an optional button to return to a given URL - * @param string alert_type - Type of warning to render alert-danger, alert-warning, alert-success etc - * @param string header - Title of warning - * @param string message - Message to display - * @param boolean show_link - True if button is to be displayed - * @param string url - URL for button - * @param string link_txt - Text for button - * @return void - */ - function render_alert($alert_type, $header, $message, $show_link = false, $url = null, $link_text = null) - { - echo '

-
'; - if ( $show_link ) { - echo '
'.$link_text.'
'; - } - - } -} - -$constellation = new Constellation(); diff --git a/classes/db-class.php b/classes/db-class.php deleted file mode 100644 index b9fe130..0000000 --- a/classes/db-class.php +++ /dev/null @@ -1,55 +0,0 @@ -query($sql) === TRUE) { - return true; - } else { - return $conn->error; - } - } - function getSetting($conn,$setting){ - $sql = "SELECT value FROM settings WHERE setting='".$setting."'"; - $result = $conn->query($sql); - - if ($result->num_rows == 1) { - while($row = $result->fetch_assoc()) { - return $row["value"]; - } - } else { - return "null"; - } - } - function setSetting($conn,$settingname,$settingvalue){ - $sql = "INSERT INTO settings (setting,value) VALUES ('".$settingname."','".$settingvalue."');"; - if ($conn->query($sql) === TRUE) { - return true; - } else { - return $conn->error; - } - - } - function deleteSetting($conn,$settingname){ - $sql = "DELETE FROM settings WHERE setting=\"".$settingname."\";"; - if ($conn->query($sql) === TRUE) { - return true; - } else { - return $conn->error; - } - - } - function updateSetting($conn, $settingname, $settingvalue){ - $this->deleteSetting($conn, $settingname); - $this->setSetting($conn, $settingname, $settingvalue); - return true; - } - - function getBooleanSetting($conn, $setting) { - if (trim($this->getSetting($conn, $setting)) == "yes"){ - return true; - } - return false; - } -} diff --git a/classes/locale-negotiator.php b/classes/locale-negotiator.php deleted file mode 100644 index b13ee23..0000000 --- a/classes/locale-negotiator.php +++ /dev/null @@ -1,315 +0,0 @@ - 'Afrikaans', - 'am_ET' => 'አማርኛ', - 'ar_AE' => 'العربية', - 'ar_BH' => 'العربية', - 'ar_DZ' => 'العربية', - 'ar_EG' => 'العربية', - 'ar_IQ' => 'العربية', - 'ar_JO' => 'العربية', - 'ar_KW' => 'العربية', - 'ar_LB' => 'العربية', - 'ar_LY' => 'العربية', - 'ar_MA' => 'العربية', - 'arn_CL' => 'Mapuche', - 'ar_OM' => 'العربية', - 'ar_QA' => 'العربية', - 'ar_SA' => 'العربية', - 'ar_SY' => 'العربية', - 'ar_TN' => 'العربية', - 'ar_YE' => 'العربية', - 'as_IN' => 'অসমীয়া', - 'az_Cyrl_AZ' => 'Азәрбајҹан', - 'az_Latn_AZ' => 'Azərbaycan', - 'ba_RU' => 'Bashkir', - 'be_BY' => 'Беларуская', - 'bg_BG' => 'Български', - 'bn_BD' => 'বাংলা', - 'bn_IN' => 'বাংলা', - 'bo_CN' => 'བོད་སྐད་', - 'br_FR' => 'Brezhoneg', - 'bs_Cyrl_BA' => 'Босански', - 'bs_Latn_BA' => 'Bosanski', - 'ca_ES' => 'Català', - 'co_FR' => 'Corsican', - 'cs_CZ' => 'Čeština', - 'cy_GB' => 'Cymraeg', - 'da_DK' => 'Dansk', - 'de_AT' => 'Deutsch', - 'de_CH' => 'Deutsch', - 'de_DE' => 'Deutsch', - 'de_LI' => 'Deutsch', - 'de_LU' => 'Deutsch', - 'dsb_DE' => 'Dolnoserbšćina', - 'dv_MV' => 'Divehi', - 'el_GR' => 'Ελληνικά', - 'en_029' => 'English', - 'en_AU' => 'English', - 'en_BZ' => 'English', - 'en_CA' => 'English', - 'en_GB' => 'English', - 'en_IE' => 'English', - 'en_IN' => 'English', - 'en_JM' => 'English', - 'en_MY' => 'English', - 'en_NZ' => 'English', - 'en_PH' => 'English', - 'en_SG' => 'English', - 'en_TT' => 'English', - 'en_US' => 'English', - 'en_ZA' => 'English', - 'en_ZW' => 'English', - 'es_AR' => 'Español', - 'es_BO' => 'Español', - 'es_CL' => 'Español', - 'es_CO' => 'Español', - 'es_CR' => 'Español', - 'es_DO' => 'Español', - 'es_EC' => 'Español', - 'es_ES' => 'Español', - 'es_GT' => 'Español', - 'es_HN' => 'Español', - 'es_MX' => 'Español', - 'es_NI' => 'Español', - 'es_PA' => 'Español', - 'es_PE' => 'Español', - 'es_PR' => 'Español', - 'es_PY' => 'Español', - 'es_SV' => 'Español', - 'es_US' => 'Español', - 'es_UY' => 'Español', - 'es_VE' => 'Español', - 'et_EE' => 'Eesti', - 'eu_ES' => 'Euskara', - 'fa_IR' => 'فارسی', - 'fi_FI' => 'Suomi', - 'fil_PH' => 'Filipino', - 'fo_FO' => 'Føroyskt', - 'fr_BE' => 'Français', - 'fr_CA' => 'Français', - 'fr_CH' => 'Français', - 'fr_FR' => 'Français', - 'fr_LU' => 'Français', - 'fr_MC' => 'Français', - 'fy_NL' => 'West_frysk', - 'ga_IE' => 'Gaeilge', - 'gd_GB' => 'Gàidhlig', - 'gl_ES' => 'Galego', - 'gsw_FR' => 'Schwiizertüütsch', - 'gu_IN' => 'ગુજરાતી', - 'ha_Latn_NG' => 'Hausa', - 'he_IL' => 'עברית', - 'hi_IN' => 'हिन्दी', - 'hr_BA' => 'Hrvatski', - 'hr_HR' => 'Hrvatski', - 'hsb_DE' => 'Hornjoserbšćina', - 'hu_HU' => 'Magyar', - 'hy_AM' => 'Հայերեն', - 'id_ID' => 'Bahasa indonesia', - 'ig_NG' => 'Igbo', - 'ii_CN' => 'ꆈꌠꉙ', - 'is_IS' => 'Íslenska', - 'it_CH' => 'Italiano', - 'it_IT' => 'Italiano', - 'iu_Cans_CA' => 'Inuktitut', - 'iu_Latn_CA' => 'Inuktitut', - 'ja_JP' => '日本語', - 'ka_GE' => 'ქართული', - 'kk_KZ' => 'Қазақ тілі', - 'kl_GL' => 'Kalaallisut', - 'km_KH' => 'ខ្មែរ', - 'kn_IN' => 'ಕನ್ನಡ', - 'kok_IN' => 'कोंकणी', - 'ko_KR' => '한국어', - 'ky_KG' => 'Кыргызча', - 'lb_LU' => 'Lëtzebuergesch', - 'lo_LA' => 'ລາວ', - 'lt_LT' => 'Lietuvių', - 'lv_LV' => 'Latviešu', - 'mi_NZ' => 'Maori', - 'mk_MK' => 'Македонски', - 'ml_IN' => 'മലയാളം', - 'mn_MN' => 'Монгол', - 'mn_Mong_CN' => 'Монгол', - 'moh_CA' => 'Mohawk', - 'mr_IN' => 'मराठी', - 'ms_BN' => 'Bahasa melayu', - 'ms_MY' => 'Bahasa melayu', - 'mt_MT' => 'Malti', - 'nb_NO' => 'Norsk bokmål', - 'ne_NP' => 'नेपाली', - 'nl_BE' => 'Nederlands', - 'nl_NL' => 'Nederlands', - 'nn_NO' => 'Nynorsk', - 'nb_NO' => 'Norsk Bokmål', - 'nso_ZA' => 'Northern sotho', - 'oc_FR' => 'Occitan', - 'or_IN' => 'ଓଡ଼ିଆ', - 'pa_IN' => 'ਪੰਜਾਬੀ', - 'pl_PL' => 'Polski', - 'prs_AF' => 'Prs', - 'ps_AF' => 'پښتو', - 'pt_BR' => 'Português', - 'pt_PT' => 'Português', - 'qut_GT' => 'Qut', - 'quz_BO' => 'Quz', - 'quz_EC' => 'Quz', - 'quz_PE' => 'Quz', - 'rm_CH' => 'Rumantsch', - 'ro_RO' => 'Română', - 'ru_RU' => 'Русский', - 'rw_RW' => 'Kinyarwanda', - 'sah_RU' => 'Саха тыла', - 'sa_IN' => 'Sanskrit', - 'se_FI' => 'Davvisámegiella', - 'se_NO' => 'Davvisámegiella', - 'se_SE' => 'Davvisámegiella', - 'si_LK' => 'සිංහල', - 'sk_SK' => 'Slovenčina', - 'sl_SI' => 'Slovenščina', - 'sma_NO' => 'Southern sami', - 'sma_SE' => 'Southern sami', - 'smj_NO' => 'Lule sami', - 'smj_SE' => 'Lule sami', - 'smn_FI' => 'Anarâškielâ', - 'sms_FI' => 'Skolt sami', - 'sq_AL' => 'Shqip', - 'sr_Cyrl_BA' => 'Српски', - 'sr_Cyrl_CS' => 'Српски', - 'sr_Cyrl_ME' => 'Српски', - 'sr_Cyrl_RS' => 'Српски', - 'sr_Latn_BA' => 'Srpski', - 'sr_Latn_CS' => 'Srpski', - 'sr_Latn_ME' => 'Srpski', - 'sr_Latn_RS' => 'Srpski', - 'sr_RS' => 'Srpski', - 'sv_FI' => 'Svenska', - 'sv_SE' => 'Svenska', - 'sw_KE' => 'Kiswahili', - 'syr_SY' => 'Syriac', - 'ta_IN' => 'தமிழ்', - 'te_IN' => 'తెలుగు', - 'tg_Cyrl_TJ' => 'Tajik', - 'th_TH' => 'ไทย', - 'tk_TM' => 'Turkmen', - 'tn_ZA' => 'Tswana', - 'tr_TR' => 'Türkçe', - 'tt_RU' => 'Tatar', - 'tzm_Latn_DZ' => 'Tamaziɣt', - 'ug_CN' => 'ئۇيغۇرچە', - 'uk_UA' => 'Українська', - 'ur_PK' => 'اردو', - 'uz_Cyrl_UZ' => 'Ўзбек', - 'uz_Latn_UZ' => 'Oʻzbekcha', - 'vi_VN' => 'Tiếng việt', - 'wo_SN' => 'Wolof', - 'xh_ZA' => 'Xhosa', - 'yo_NG' => 'Èdè yorùbá', - 'zh_CN' => '中文', - 'zh_HK' => '中文', - 'zh_MO' => '中文', - 'zh_SG' => '中文', - 'zh_TW' => '中文', - 'zu_ZA' => 'Isizulu', - ); - - /** - * This method scans for languages and creates a list of language and its name (localized ofc.) - * @param String $default_language language displayed to user in case no suitable lang is found - */ - function __construct($default_language) - { - $tmp = glob(__DIR__ . '/../locale/*' , GLOB_ONLYDIR); - $this->default_language = $default_language; - //Works only if the server supports the locale - //This basically means $accepted_langs[] = ""; - foreach ($tmp as $value) { - $lang = basename($value); - $this->accepted_langs[$lang] = $this->all_locales[$lang]; - } - } - - /** - * Returns list of accepted langs so it can be reused for rendering language list for switching... - */ - public function get_accepted_langs(){ - return $this->accepted_langs; - } - - /** - * This method does the actual negotiation. It has override parameter in case user wants to switch - * languages. - * @param String $override adds language to list of preffered languages with highest priority - * @return String language code that matched best with browser preferences - */ - public function negotiate($override = null){ - $langs = []; - - if (isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) { - $http_accept_language = str_replace("-", "_", $_SERVER['HTTP_ACCEPT_LANGUAGE']); - preg_match_all('/([a-z]{1,8}(-[a-z]{1,8})?)\s*(;\s*q\s*=\s*(1|0\.[0-9]+))?/i', $http_accept_language, $lang_parse); - - if (count($lang_parse[1])) { - $langs = array_combine($lang_parse[1], $lang_parse[4]); - - foreach ($langs as $lang => $val) { - //If browser didn't send quality of language, it is 1 by default - if ($val === '') $langs[$lang] = 1; - } - - if (isset($override)) - { - //More important than the best lang of browser - $langs[$override] = 2; - } - - arsort($langs, SORT_NUMERIC); - } - } - - //So we have lang code as value - $langs = array_flip($langs); - //False unless we set it, so we know to set default locale - $best_match = false; - //So we have also lang code as value - $accepted_langs = array_flip($this->accepted_langs); - - global $lang; - foreach ($langs as $lang) { - if (strlen($lang)>2){ - if (in_array($lang, $accepted_langs)){ - $best_match = $lang; - break; - } - }else{ - $possible = array_filter($accepted_langs, function($key) { - global $lang; - return strpos($key, $lang) === 0; - }); - - if (count($possible)){ - foreach ($possible as $value) { - $best_match = $value; - } - break; - } - } - } - - if ($best_match === false){ - $best_match = $this->default_language; - } - - return $best_match; - } -} - diff --git a/classes/mailer.php b/classes/mailer.php deleted file mode 100644 index 4a716b6..0000000 --- a/classes/mailer.php +++ /dev/null @@ -1,174 +0,0 @@ -is_utf8($to) ) { - $elements = explode('@', $to); - $domainpart = EncodePunycodeIDN(array_pop($elements)); // Convert domain part to ascii - $to = $elements[0] . '@' . $domainpart; // Reassemble tge full email address - } - - // Send using PHP mailer if it is enabled - if ( PHP_MAILER ) { - require_once(PHP_MAILER_PATH .'/Exception.php'); /* Exception class. */ - require_once(PHP_MAILER_PATH .'/PHPMailer.php'); /* The main PHPMailer class. */ - - if ( PHP_MAILER_SMTP ) { - require_once(PHP_MAILER_PATH .'/SMTP.php'); /* SMTP class, needed if you want to use SMTP. */ - } - - $phpmail = new PHPMailer(false); - - $phpmail->setFrom(MAILER_ADDRESS, MAILER_NAME); - $phpmail->addReplyTo(MAILER_ADDRESS, MAILER_NAME); - //$phpmail->Debugoutput = error_log; - - // Define SMTP parameters if enabled - if ( PHP_MAILER_SMTP ) { - - $phpmail->isSMTP(); - $phpmail->Host = PHP_MAILER_HOST; - $phpmail->Port = PHP_MAILER_PORT; - $phpmail->SMTPSecure = PHP_MAILER_SECURE; - //$phpmail->SMTPDebug = 2; // Enable for debugging - - // Handle authentication for SMTP if enabled - if ( !empty(PHP_MAILER_USER) ) { - $phpmail->SMTPAuth = true; - $phpmail->Username = PHP_MAILER_USER; - $phpmail->Password = PHP_MAILER_PASS; - } - } - - $phpmail->addAddress($to); - $phpmail->Subject = $subject; - // Send HMTL mail - if ( $html ) { - $phpmail->msgHtml($message); - $phpmail->AltBody = $this->convert_html_to_plain_txt($message, false); - } else { - $phpmail->Body = $message; // Send plain text - } - - $phpmail->isHtml($html); // use htmlmail if enabled - if ( ! $phpmail->send() ) { - // TODO Log error message $phpmail->ErrorInfo; - return false; - } - return true; - - } else { - // Use standard PHP mail() function - $headers = "Content-Type: $content_type; \"charset=utf-8\" ".PHP_EOL; - $headers .= "MIME-Version: 1.0 ".PHP_EOL; - $headers .= "From: ".MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; - $headers .= "Reply-To: ".MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; - - mail($to, $subject, $message, $headers); - // TODO log error message if mail fails - return true; - } - - } - /** - * Tries to verify the domain using dns request against an MX record of the domain part - * of the passed email address. The code also handles IDN/Punycode formatted addresses which - * contains utf8 characters. - * Original code from https://stackoverflow.com/questions/19261987/how-to-check-if-an-email-address-is-real-or-valid-using-php/19262381 - * @param String $email Email address to check - * @return boolean True if MX record exits, false if otherwise - */ - public function verify_domain($email){ - // TODO - Handle idn/punycode domain names without being dependent on PHP native libs. - $domain = explode('@', $email); - $domain = EncodePunycodeIDN(array_pop($domain).'.'); // Add dot at end of domain to avoid local domain lookups - syslog(1,$domain); - return checkdnsrr($domain, 'MX'); - } - - - /** - * Check if string contains non-english characters (detect IDN/Punycode enabled domains) - * Original code from: https://stackoverflow.com/questions/13120475/detect-non-english-chars-in-a-string - * @param String $str String to check for extended characters - * @return boolean True if extended characters, false otherwise - */ - public function is_utf8($str) - { - if (strlen($str) == strlen(utf8_decode($str))) { - return false; - } else { - return true; - } - } - - /** - * Takes the input from an HTML email and convert it to plain text - * This is commonly used when sending HTML emails as a backup for email clients who can only view, or who choose to only view, - * Original code from https://github.com/DukeOfMarshall/PHP---JSON-Email-Verification/blob/master/EmailVerify.class.php - * plain text emails - * @param string $content The body part of the email to convert to plain text. - * @param boolean $remove_links Set to true if links should be removed from email - * @return String pain text version - */ - public function convert_html_to_plain_txt($content, $remove_links=false){ - // TODO does not handle unsubscribe/manage subscription text very well. - // Replace HTML line breaks with text line breaks - $plain_text = str_ireplace(array("
","
"), "\n\r", $content); - - // Remove the content between the tags that wouldn't normally get removed with the strip_tags function - $plain_text = preg_replace(array('@]*?>.*?@siu', - '@]*?>.*?@siu', - '@]*?.*?@siu', - '@]*?.*?@siu', - ), "", $plain_text); // Remove everything from between the tags that doesn't get removed with strip_tags function - - // If the user has chosen to preserve the addresses from links - if(!$remove_links){ - $plain_text = strip_tags(preg_replace('//', ' $1 ', $plain_text)); - } - - // Remove HTML spaces - $plain_text = str_replace(" ", "", $plain_text); - - // Replace multiple line breaks with a single line break - $plain_text = preg_replace("/(\s){3,}/","\r\n\r\n",trim($plain_text)); - - return $plain_text; - } - -} diff --git a/classes/notification.php b/classes/notification.php deleted file mode 100644 index 762bbd7..0000000 --- a/classes/notification.php +++ /dev/null @@ -1,197 +0,0 @@ -prepare("SELECT services.id, services.name FROM services INNER JOIN services_status on services.id = services_status.service_id WHERE services_status.status_id = ?"); - $stmt->bind_param("i", $status_id); - $stmt->execute(); - $query = $stmt->get_result(); - $arrServicesNames = array(); - $arrServicesId = array(); - while ($result = $query->fetch_assoc()) { - $arrServicesNames[] = $result['name']; - $arrServicesId[] = (int) $result['id']; - } - $this->status_id = $status_id; - $this->servicenames = implode(",", $arrServicesNames); - $this->serviceids = implode(",", $arrServicesId); - return true; - } else { - return false; - } - } - - /** - * Loop over the list of subscribers to notify depending on impacted service(s) and - * call the differnet notification handles. - * @return void - */ - public function notify_subscribers() - { - global $mysqli; - // Fetch list of unique subscribers for given service - // Direct inclusion of variable without using prepare justified by the fact that - // this->serviceids are not user submitted - $sql = "SELECT DISTINCT subscriberIDFK FROM services_subscriber WHERE serviceIDFK IN (" . $this->serviceids . ")"; - $query = $mysqli->query($sql); - - // Create the queue tasks for email/telegram notifications - $queue = new Queue(); - $queue->status = $queue->all_status['populating']; - $queue->user_id = $_SESSION['user']; - - $arr_data = array(); - if ( SUBSCRIBE_EMAIL ) { - $arr_data = $this->prepare_email(); // Make up the base message and subject for email - $queue->type_id = $queue->all_type_id['notify_email']; - $queue->template_data1 = $arr_data['subject']; - $queue->template_data2 = $arr_data['body']; - $task_id_email = $queue->add_task(); - //syslog(1, "queue email: ". $task_id_email); - $arr_email = array(); - } - if ( SUBSCRIBE_TELEGRAM ) { - $arr_data = $this->prepare_telegram(); - $queue->type_id = $queue->all_type_id['notify_telegram']; - $queue->template_data1 = null; - $queue->template_data2 = $arr_data['body']; - $task_id_telegram = $queue->add_task(); - //syslog(1, "queue telegram: ". $task_id_telegram); - $arr_telegram = array(); - } - - while ($subscriber = $query->fetch_assoc()) { - // Fetch list of subscriber details for already found subscriber IDs - $stmt = $mysqli->prepare("SELECT typeID FROM subscribers WHERE subscriberID = ? AND active=1"); - $stmt->bind_param("i", $subscriber['subscriberIDFK']); - $stmt->execute(); - $subscriberQuery = $stmt->get_result(); - - while ($subscriberData = $subscriberQuery->fetch_assoc()) { - $typeID = $subscriberData['typeID']; // Telegram = 1, email = 2 - - // Handle telegram - if ($typeID == 1 && SUBSCRIBE_TELEGRAM) { - $arr_telegram[] = $subscriber['subscriberIDFK']; - } - // Handle email - if ($typeID == 2 && SUBSCRIBE_EMAIL) { - $arr_email[] = $subscriber['subscriberIDFK']; - } - - } - - } - - if ( SUBSCRIBE_TELEGRAM) { - $queue->task_id = $task_id_telegram; - $queue->add_notification($arr_telegram); // Add array of Telegram users to the notification queue list - } - if ( SUBSCRIBE_EMAIL ) { - $queue->task_id = $task_id_email; - $queue->add_notification($arr_email); // Add array of Email users to the notification queue list - } - } - - /** - * Sends Telegram notification message using their web api. - * @param string $userID The Telegram userid to send to - * @param string $firstname The users firstname - * @param string $msg Body of message - * @return boolean true = Sent / False = failed - */ - public function submit_queue_telegram($userID, $firstname, $msg) - { - // TODO Handle limitations (Max 30 different subscribers per second) - // TODO Error handling - $msg = sprintf($msg, $firstname); - - $tg_message = array('text' => $msg, 'chat_id' => $userID, 'parse_mode' => 'HTML'); - $json = @file_get_contents("https://api.telegram.org/bot" . TG_BOT_API_TOKEN . "/sendMessage?" . http_build_query($tg_message) ); - - $response = json_decode($json, true); - - if (!is_array($response) || ! array_key_exists("ok", $response) || $response['ok'] != 1 ) { - return false; - - } - return true; - } - - /** - * Sends email notifications to a subscriber. - * Function depends on Parsedown and Mailer class being loaded. - * @param String $userID The email address to send to - * @param String $uthkey Users token for managing subscription - * @return void - */ - public function submit_queue_email($subscriber, $subject, $msg) - { - // TODO Error handling - $mailer = new Mailer(); - if ( ! $mailer->send_mail($subscriber, $subject, $msg, true) ) { - return false; - } - return true; - } - - public function prepare_email(){ - - $Parsedown = new Parsedown(); - $str_mail = file_get_contents("../libs/templates/email_status_update.html"); - $str_mail = str_replace("%name%", NAME, $str_mail); - // $smtp_mail = str_replace("%email%", $userID, $smtp_mail); - $str_mail = str_replace("%url%", WEB_URL, $str_mail); - $str_mail = str_replace("%service%", $this->servicenames, $str_mail); - $str_mail = str_replace("%status%", $this->status, $str_mail); - $str_mail = str_replace("%time%", date("c", $this->time), $str_mail); - $str_mail = str_replace("%comment%", $Parsedown->setBreaksEnabled(true)->text($this->text), $str_mail); - //$str_mail = str_replace("%token%", $token, $str_mail); - - $str_mail = str_replace("%service_status_update_from%", _("Service status update from"), $str_mail); - $str_mail = str_replace("%services_impacted%", _("Service(s) Impacted"), $str_mail); - $str_mail = str_replace("%status_label%", _("Status"), $str_mail); - $str_mail = str_replace("%time_label%", _("Time"), $str_mail); - $str_mail = str_replace("%manage_subscription%", _("Manage subscription"), $str_mail); - $str_mail = str_replace("%unsubscribe%", _("Unsubscribe"), $str_mail); - $str_mail = str_replace("%powered_by%", _("Powered by"), $str_mail); - - $subject = _('Status update from') . ' - ' . NAME . ' [ ' . $this->status . ' ]'; - - $val = array(); - $val['subject'] = $subject; - $val['body'] = $str_mail; - return $val; - } - - public function prepare_telegram(){ - $msg = _("Hi #s!\nThere is a status update for service(s): %s\nThe new status is: %s\nTitle: %s\n\n%s\n\nView online"); - $val['body'] = sprintf($msg, $this->servicenames, $this->status, $this->title, $this->text, WEB_URL); - return $val; - } -} diff --git a/classes/queue.php b/classes/queue.php deleted file mode 100644 index dd8187c..0000000 --- a/classes/queue.php +++ /dev/null @@ -1,161 +0,0 @@ - 1, - 'notify_email' => 2); - - public $all_status = array('populating' => 1, - 'ready' => 2, - 'processing' => 3, - 'completed' => 4, - 'failed' => 5); - - public function add_task() { - global $mysqli; - $stmt = $mysqli->prepare("INSERT INTO queue_task (type_id, status, template_data1, template_data2, created_time, user_id) VALUES (?,?,?,?,?,?)"); - if ( false===$stmt ) { - //die('prepare() failed: ' . htmlspecialchars($mysqli->error)); - echo $mysqli->errno(); - - } - #if ( false === $stmt ) { syslog(1, "Error :". $mysqli->error); } - $now = time(); - $res = $stmt->bind_param("iissii", $this->type_id, $this->status, $this->template_data1, $this->template_data2, $now, $this->user_id); - if ( false === $res ) { - echo "error"; - die(); - } - $stmt->execute(); - $query = $stmt->get_result(); - print $query; - $this->task_id = $mysqli->insert_id; - return $this->task_id; - } - - /** - * Remove task from the queue - * @return void - */ - public function delete_task($task_id){ - global $mysqli; - $stmt = $mysqli->prepare("DELETE FROM queue_task WHERE id = ?"); - $stmt->bind_param("i", $task_id); - $stmt->execute(); - } - - /** - * Update status for given task - * @param int $new_status The new current status of the task. Must be selected from the $all_status array. - * @return void - */ - public function set_task_status($new_status) { - global $mysqli; - $stmt = $mysqli->prepare("UPDATE queue_task SET status = ? WHERE id = ?"); - $stmt->bind_param("ii", $new_status, $this->task_id); - $stmt->execute(); - $this->status = $new_status; - } - - /** - * Add notification queue data for given task - * @param array $arr_data Array filled with subscriber_id - * @return void - */ - public function add_notification($arr_data) { - global $mysqli; - - //Default status = 1, retres = 0, task_id = $this->task_id - - // Build query manually since mysqli doesn't cater well for multi insert.. - $count = count($arr_data); // Let's find number of elements - $counter = 0; - $query = ''; - $seperator = ','; - $sub_query = '(%d, %d, %d ,%d)%s'; - - foreach ($arr_data as $value) { - $counter++; - if ($counter == $count) { $seperator = ''; } // Make sure last character for SQL query is correct - $query .= sprintf($sub_query, $this->task_id, 1, $value, 0, $seperator); - } - $sql = "INSERT INTO queue_notify (task_id, status, subscriber_id, retries) VALUES ". $query; - - $mysqli->query($sql); - - $this->set_task_status($this->all_status['ready']); // Make task available for release - } - - public function update_notification_retries($task_id, $subscriber_id) { - global $mysqli; - $stmt = $mysqli->prepare("UPDATE queue_notify SET retries = retries+1 WHERE task_id = ? AND subscriber_id = ?"); - $stmt->bind_param("ii", $task_id, $subscriber_id); - $stmt->execute(); - } - - public function delete_notification($task_id, $subscriber_id) { - global $mysqli; - $stmt = $mysqli->prepare("DELETE FROM queue_notify WHERE task_id = ? AND subscriber_id = ?"); - $stmt->bind_param("ii", $task_id, $subscriber_id); - $stmt->execute(); - - } - - // TODO: Fix max attempts for notifications - public function process_queue(){ - global $mysqli; - $stmt = $mysqli->query("SELECT qn.id, qn.task_id, qn.status, qn.subscriber_id, qn.retries, sub.firstname, sub.userID, sub.token FROM queue_notify AS qn INNER JOIN subscribers AS sub ON qn.subscriber_id = sub.subscriberID WHERE qn.status NOT LIKE 2 AND sub.active=1"); - while ( $result = $stmt->fetch_assoc() ) { - - $i = 2; - $stmt2 = $mysqli->prepare("SELECT * FROM queue_task WHERE id = ? AND status = ?"); - $stmt2->bind_param("ii", $result['task_id'], $i); - $stmt2->execute(); - $tmp = $stmt2->get_result(); - $result2 = $tmp->fetch_assoc(); - $typeID = $result2['type_id']; - - // Handle telegram - if ($typeID == 1) { - $msg = str_replace("#s", $result['firstname'], $result2['template_data2']); - if ( ! Notification::submit_queue_telegram($result['userID'], $result['firstname'], $msg) ) { - Queue::update_notification_retries($result['task_id'], $result['subscriber_id']); // Sent - } else { - Queue::delete_notification($result['task_id'], $result['subscriber_id']); // Failed - } - } - - // Handle email - if ($typeID == 2) { - $msg = str_replace("%token%", $result['token'], $result2['template_data2']); - if ( ! Notification::submit_queue_email($result['userID'], $result2['template_data1'], $msg) ) { - Queue::update_notification_retries($result['task_id'], $result['subscriber_id']); // Sent - - } else { - Queue::delete_notification($result['task_id'], $result['subscriber_id']); // Failed - } - } - } - - // Check if queue log is empty and if so delete the queue_task - $stmt = $mysqli->query("SELECT id, (SELECT COUNT(*) FROM queue_notify AS qn WHERE qn.task_id = queue_task.id) AS count FROM queue_task"); - while ( $result = $stmt->fetch_assoc() ) { - if ( $result['count'] == 0 ) { - Queue::delete_task($result['id']); - } - } - - } -} diff --git a/classes/service-group.php b/classes/service-group.php deleted file mode 100644 index 933571a..0000000 --- a/classes/service-group.php +++ /dev/null @@ -1,167 +0,0 @@ -id = $id; - $this->name = $name; - $this->description = $description; - $this->visibility_id = $visibility_id; - $this->status = $status; - } - - /** - * Returns id of this servicegroup - * @return int id - */ - public function get_id() - { - return $this->id; - } - - /** - * Returns name of this servicegroup - * @return String name - */ - public function get_name() - { - return $this->name; - } - - /** - * Returns description of this servicegroup - * @return String description - */ - public function get_description() - { - return $this->description; - } - - /** - * Processes submitted form and adds service unless problem is encountered, - * calling this is possible only for admin or higher rank. Also checks requirements - * for char limits. - * @return void - */ - public static function add() - { - global $user, $message; - if (strlen($_POST['group'])>50) - { - $message = _("Service group name is too long! Character limit is 50"); - return; - }else if (strlen(trim($_POST['group']))==0){ - $message = _("Please enter name!"); - return; - } - - if ($user->get_rank()<=1) - { - global $mysqli; - $name = $_POST["group"]; - $description = $_POST["description"]; - $visibility_id = $_POST["visibility_id"]; - $stmt = $mysqli->prepare("INSERT INTO services_groups VALUES(NULL,?,?,?)"); - $stmt->bind_param("ssi", $name, $description, $visibility_id); - $stmt->execute(); - $stmt->get_result(); - header("Location: ".WEB_URL."/admin/?do=settings"); - }else - { - $message = _("You don't have the permission to do that!"); - } - } - - public static function edit() - { - global $user, $message; - if (strlen($_POST['group'])>50) - { - $message = _("Service group name is too long! Character limit is 50"); - return; - }else if (strlen(trim($_POST['group']))==0){ - $message = _("Please enter name!"); - return; - } - - if ($user->get_rank()<=1) - { - global $mysqli; - $name = $_POST["group"]; - $description = $_POST["description"]; - $visibility_id = $_POST["visibility_id"]; - $group_id = $_POST["id"]; - $stmt = $mysqli->prepare("UPDATE services_groups SET name=?, description=?,visibility=? WHERE id LIKE ?"); - $stmt->bind_param("ssii", $name, $description, $visibility_id, $group_id); - $stmt->execute(); - $stmt->get_result(); - header("Location: ".WEB_URL."/admin/?do=settings"); - }else - { - $message = _("You don't have the permission to do that!"); - } - } - /** - * Deletes this service - first checks if user has permission to do that. - * @return void - */ - public static function delete() - { - global $user, $message; - if ($user->get_rank()<=1) - { - global $mysqli; - $id = $_GET['delete']; - - $stmt = $mysqli->prepare("DELETE FROM services_groups WHERE id = ?"); - $stmt->bind_param("i", $id); - $stmt->execute(); - $query = $stmt->get_result(); - - $stmt = $mysqli->prepare("UPDATE services SET group_id = NULL WHERE group_id = ?"); - $stmt->bind_param("i", $id); - $stmt->execute(); - $query = $stmt->get_result(); - - header("Location: ".WEB_URL."/admin/?do=settings"); - } - else - { - $message = _("You don't have the permission to do that!"); - } - } - - - /** - * Get list of services groups. - * @return array $groups - */ - public function get_groups() { - global $mysqli; - $stmt = $mysqli->query("SELECT id, name FROM services_groups ORDER by name ASC"); - - $groups = array(); - $groups[0] = ''; - while ($res = $stmt->fetch_assoc()) { - $groups[$res['id']] = $res['name']; - } - return $groups; - } -} diff --git a/classes/service.php b/classes/service.php deleted file mode 100644 index 268715c..0000000 --- a/classes/service.php +++ /dev/null @@ -1,272 +0,0 @@ -id = $id; - $this->name = $name; - $this->description = $description; - $this->group_name = $group_name; - $this->status = $status; - } - - /** - * Returns status of this service - * @return int status - */ - public function get_status() - { - return $this->status; - } - - /** - * Returns id of this service - * @return int id - */ - public function get_id() - { - return $this->id; - } - - /** - * Returns name of this service - * @return String name - */ - public function get_name() - { - return $this->name; - } - - /** - * Returns description of this service - * @return String description - */ - public function get_description() - { - return $this->description; - } - - /** - * Processes submitted form and adds service unless problem is encountered, - * calling this is possible only for admin or higher rank. Also checks requirements - * for char limits. - * @return void - */ - public static function add() - { - global $user, $message; - if (strlen($_POST['service'])>50) - { - $message = _("Service name is too long! Character limit is 50"); - return; - }else if (strlen(trim($_POST['service']))==0){ - $message = _("Please enter name!"); - return; - } - - if ($user->get_rank()<=1) - { - global $mysqli; - $name = htmlspecialchars($_POST['service']); - $description = htmlspecialchars($_POST['description']); - $group_id = $_POST['group_id']; - $stmt = $mysqli->prepare("INSERT INTO services ( name, description, group_id ) VALUES ( ?, ?, ? )"); - $stmt->bind_param("ssi", $name, $description, $group_id); - $stmt->execute(); - $stmt->get_result(); - header("Location: ".WEB_URL."/admin/?do=settings"); - }else - { - $message = _("You don't have the permission to do that!"); - } - } - /** - * Processes submitted form and adds service unless problem is encountered, - * calling this is possible only for admin or higher rank. Also checks requirements - * for char limits. - * @return void - */ - public static function edit() - { - global $user, $message; - if (strlen($_POST['service'])>50) - { - $message = _("Service name is too long! Character limit is 50"); - return; - }else if (strlen(trim($_POST['service']))==0){ - $message = _("Please enter name!"); - return; - } - - if ($user->get_rank()<=1) - { - global $mysqli; - $service_id = $_POST["id"]; - $name = htmlspecialchars($_POST['service']); - $description = htmlspecialchars($_POST["description"]); - $group_id = $_POST["group_id"]; - $stmt = $mysqli->prepare("UPDATE services SET name=?, description=?, group_id=? WHERE id = ?"); - $stmt->bind_param("ssii", $name, $description, $group_id, $service_id); - $stmt->execute(); - $stmt->get_result(); - header("Location: ".WEB_URL."/admin/?do=settings"); - }else - { - $message = _("You don't have the permission to do that!"); - } - } - - /** - * Deletes this service - first checks if user has permission to do that. - * @return void - */ - public static function delete() - { - global $user, $message; - if ($user->get_rank()<=1) - { - global $mysqli; - $id = $_GET['delete']; - - $stmt = $mysqli->prepare("SELECT status_id as status, (SELECT count(*) FROM services_status as s WHERE s.status_id=status) as count FROM services_status WHERE service_id = ? GROUP BY status"); - $stmt->bind_param("i", $id); - $stmt->execute(); - $query = $stmt->get_result(); - - while ($res = $query->fetch_assoc()) { - if ($res['count']==1) - { - Incident::delete($res['status']); - } - } - - $stmt = $mysqli->prepare("DELETE FROM services WHERE id = ?"); - $stmt->bind_param("i", $id); - $stmt->execute(); - $query = $stmt->get_result(); - - $stmt = $mysqli->prepare("DELETE FROM services_status WHERE service_id = ?"); - $stmt->bind_param("i", $id); - $stmt->execute(); - $query = $stmt->get_result(); - - header("Location: ".WEB_URL."/admin/?do=settings"); - } - else - { - $message = _("You don't have the permission to do that!"); - } - } - - /** - * Renders current status for services from passed array of services. - * @param Service[] $array array of services - * @return void - */ - public static function current_status($array){ - global $all, $some, $classes; - $statuses = array(0,0,0,0); - $worst = 5; - - foreach ($array as $service) { - if ($service->status<$worst) - { - $worst = $service->get_status(); - } - $statuses[$service->get_status()]++; - } - - echo '
'; - - if ($statuses[$worst] == count($array)) - { - echo $all[$worst]; - }else{ - echo $some[$worst]; - } - echo '
'; - } - - /** - * Renders this service. - * @param $boolGroup set to true if the groups name is to be rendered - * @return void - */ - public function render(){ - global $statuses; - global $classes; - static $arrCompletedGroups = array(); - //static $boolClosed; - static $boolOpened; - - // Check if previous ul has been opened, and if a empty/new group is being - // render_header, close the UL first. - if ( $boolOpened ) { - if ( empty($this->group_name) || !in_array($this->group_name, $arrCompletedGroups) ) { - echo ''; - $boolOpened = false; - } - } - - // If no group exist or group is new, start a new UL - if ( !empty($this->group_name) && !in_array($this->group_name, $arrCompletedGroups)) { - echo '
    '; - //echo '
      '; - // Render the group status if it exists - echo '
    •  ' . $this->group_name .'
      '. _($statuses[$this->status]).'
    • '; - //echo '
    • ' . $this->group_name .'
      status]).'
    • '; - $arrCompletedGroups[] = $this->group_name; - $boolOpened = true; - } - - if ( empty($this->group_name)) { - echo '
        '; - -// echo '
          '; - $boolFinish = true; - } - - // Render the service status - echo '
        • ' . $this->name .''; - //echo '
        • ' . $this->name . ''; - if(!empty($this->description)) { - echo ' '; - } - if ($this->status!=-1){?>
          status]);?>
          - '; - if ( isset($boolFinish) && $boolFinish) { - echo '
        '; - } - } - - public function jsonSerialize() { - global $statuses; - return [ - "id" => $this->id, - "name" => $this->name, - "description" => $this->description, - "status" => $this->status, - "status_string" => $statuses[$this->status] - ]; - } - -} diff --git a/classes/subscriber.php b/classes/subscriber.php deleted file mode 100644 index 0fef6fd..0000000 --- a/classes/subscriber.php +++ /dev/null @@ -1,329 +0,0 @@ -firstname = null; - $this->lastname = null; - $this->userID = ""; - $this->token = null; - $this->active = 0; - $this->typeID = null; - } - - /** - * Gets authentcation token for specified subscriberID - * @param Integer $subscriberID - specifies which subscriber we are looking up - * @param Integer $typeID - specifies which type of subscription we are refering (1 = telegram, 2 = email) - * @return String $token - 32 bytes HEX string - */ - public function get_token($subscriberID, $typeID) - { - global $mysqli; - $stmt = $mysqli->prepare("SELECT token FROM subscribers WHERE subscriberID = ? and typeID=? and active = 1 LIMIT 1"); - $stmt->bind_param("ii", $subscriberID, $typeID); - $stmt->execute(); - $result = $stmt->get_result(); - if ($result->num_rows > 0) { - $row = $result->fetch_assoc(); - $this->token = $row['token']; - //$this->get_subscriber_by_token($this->token); - return $row['token']; - } - return false; - - } - public function get_subscriber_by_token($token) - { - global $mysqli; - $stmt = $mysqli->prepare("SELECT subscriberID FROM subscribers WHERE token=? and typeID=?"); - $stmt->bind_param("si", $token, $this->typeID); - $stmt->execute(); - $result = $stmt->get_result(); - if ($result->num_rows > 0) { - $row = $result->fetch_assoc(); - $this->id = $row['subscriberID']; - $this->populate(); // - return true; - } - return false; - } - - public function get_subscriber_by_userid($create = false) - { - global $mysqli; - $stmt = $mysqli->prepare("SELECT subscriberID FROM subscribers WHERE userID LIKE ? AND typeID = ? LIMIT 1"); - $stmt->bind_param("si", $this->userID, $this->typeID ); - $stmt->execute(); - $result = $stmt->get_result(); - - if ($result->num_rows > 0) { - $row = $result->fetch_assoc(); - $this->id = $row['subscriberID']; - $this->populate(); - return $row['subscriberID']; - } else { - // User is not registered in DB, so add if $create = true - if ( $create ) { - $subscriber_id = $this->add($this->typeID, $this->userID, $this->active, $this->firstname, $this->lastname); - return $subscriber_id; - } - return false; - } - } - - public function populate() - { - global $mysqli; - $stmt = $mysqli->prepare("SELECT typeID, userID, firstname, lastname, token, active FROM subscribers WHERE subscriberID = ?"); - $stmt->bind_param("i", $this->id); - $stmt->execute(); - $result = $stmt->get_result(); - if ($result->num_rows > 0) { - $row = $result->fetch_assoc(); - $this->userID = $row['userID']; - $this->typeID = $row['typeID']; - $this->firstname = $row['firstname']; - $this->lastname = $row['lastname']; - $this->token = $row['token']; - $this->active = $row['active']; - return true; - } - return false; - } - - public function add($typeID, $userID, $active = null, $firstname = null, $lastname = null) - { - global $mysqli; - $expireTime = strtotime("+2 hours"); - $updateTime = strtotime("now"); - $token = $this->generate_token(); - - $stmt = $mysqli->prepare("INSERT INTO subscribers (typeID, userID, firstname, lastname, token, active, expires, create_time) VALUES (?, ?, ?, ?, ?, ?, ?, ?)"); - $stmt->bind_param("issssiii", $typeID, $userID, $firstname, $lastname, $token, $active, $expireTime, $updateTime); - $stmt->execute(); - //$query = $stmt->get_result(); - - $this->id = $mysqli->insert_id; - $this->typeID = $typeID; - $this->userID = $userID; - $this->token = $token; - $this->firstname = $firstname; - $this->lastname = $lastname; - $this->active = $active; - return $this->id; - } - - public function update($subscriberID) - { - global $mysqli; - $updateTime = strtotime("now"); - $stmt = $mysqli->prepare("UPDATE subscribers SET update_time = ? WHERE subscriberID=?"); - $stmt->bind_param("ii", $updateTime, $subscriberID); - $stmt->execute(); - return true; - - } - - public function activate($subscriberID) - { - global $mysqli; - $updateTime = strtotime("now"); - - $stmt = $mysqli->prepare("UPDATE subscribers SET update_time = ?, expires = ? WHERE subscriberID = ?"); - $tmp = null; - $stmt->bind_param("iii", $updateTime, $tmp, $subscriberID); - $stmt->execute(); - return true; - } - - public function delete($subscriberID) - { - global $mysqli; - - $stmt = $mysqli->prepare("DELETE FROM services_subscriber WHERE subscriberIDFK = ?"); - $stmt->bind_param("i", $subscriberID); - $stmt->execute(); - //$query = $stmt->get_result(); - - $stmt = $mysqli->prepare("DELETE FROM subscribers WHERE subscriberID = ?"); - $stmt->bind_param("i", $subscriberID); - $stmt->execute(); - //$query = $stmt->get_result(); - return true; - - } - - public function check_userid_exist() - { - global $mysqli; - - $stmt = $mysqli->prepare("SELECT subscriberID, userID, token, active FROM subscribers WHERE typeID=? AND userID=? LIMIT 1"); - - $stmt->bind_param("is", $this->typeID, $this->userID); - $stmt->execute(); - $result = $stmt->get_result(); - - if($result->num_rows > 0) { - $row = $result->fetch_assoc(); - $this->id = $row['subscriberID']; - $this->populate(); - return true; - } - return false; - } - - public function is_active_subscriber($token) - { - global $mysqli; - - - $stmt = $mysqli->prepare("SELECT subscriberID, token, userID, active, expires FROM subscribers WHERE token LIKE ? LIMIT 1"); - $stmt->bind_param("s", $token ); - $stmt->execute(); - $result = $stmt->get_result(); - - if ($result->num_rows > 0) { - $row = $result->fetch_assoc(); - } else { - // No data found, fail gently... - return false; - } - - // If account is not already active, check if we are within timeframe of exipre +2h - // and active if so, otherwise,delete account and return falsev - if ( $row['active'] <> 1 ) { - - // Calculate time range for when subscription need to be validated - $time_end = $row['expires']; - $time_start = $time_end - (3600*2); // TODO - make this interval configurable via a config option - $time_now = time(); - - if ( ($time_now > $time_start) && ($time_now < $time_end) ) { - // Timefram is within range, active user.. - $stmt2 = $mysqli->prepare("UPDATE subscribers SET active=1, expires=null WHERE subscriberID = ?"); - $stmt2->bind_param("i", $row['subscriberID']); - $stmt2->execute(); - $result = $stmt2->get_result(); - $this->active = 1; - $this->id = $row['subscriberID']; - $this->userID = $row['userID']; - $this->token = $row['token']; - return true; - - } else { - // Timeframe outside of given scope -> delete account - $stmt2 = $mysqli->prepare("DELETE FROM subscribers WHERE subscriberID = ?"); - $stmt2->bind_param("i", $row['subscriberID']); - $stmt2->execute(); - $result = $stmt2->get_result(); - $this->active = 0; - return false; - } - } - - // if we get here, account should already be active - $this->active = 1; - $this->id = $row['subscriberID']; - $this->userID = $row['userID']; - $this->token = $row['token']; - return true; - } - - /** - * Generate a new 64 byte token (32 bytes converted from bin2hex = 64 bytes) - * @return string token - */ - public function generate_token() - { - global $mysqli; - - if ( function_exists('openssl_random_pseudo_bytes') ) { - $token = openssl_random_pseudo_bytes(32); //Generate a random string. - $token = bin2hex($token); //Convert the binary data into hexadecimal representation. - } else { - // Use alternative token generator if openssl isn't available... - $token = make_alt_token(32, 32); - } - - // Make sure token doesn't already exist in db - $stmt = $mysqli->prepare("SELECT subscriberID FROM subscribers WHERE token LIKE ?"); - echo $mysqli->error; - $stmt->bind_param("s", $token); - $stmt->execute(); - $result = $stmt->get_result(); - if ($result->num_rows > 0 ) { - // token already exists, call self again - $token = $this->generate_token(); - } - - return $token; - } - - /** - * Alternative token generator if openssl_random_pseudo_bytes is not available - * Original code by jsheets at shadonet dot com from http://php.net/manual/en/function.mt-rand.php - * @params int min_length Minimum length of token - * @params int max_length Maximum length of token - * @return String token - */ - public function make_alt_token($min_length = 32, $max_length = 64) - { - $key = ''; - - // build range and shuffle range using ASCII table - for ($i=0; $i<=255; $i++) { - $range[] = chr($i); - } - - // shuffle our range 3 times - for ($i=0; $i<=3; $i++) { - shuffle($range); - } - - // loop for random number generation - for ($i = 0; $i < mt_rand($min_length, $max_length); $i++) { - $key .= $range[mt_rand(0, count($range)-1)]; - } - - $return = bin2hex($key); - - if (!empty($return)) { - return $return; - } else { - return 0; - } - } - - public function set_logged_in() - { - $_SESSION['subscriber_valid'] = true; - $_SESSION['subscriber_id'] = $this->id; - $_SESSION['subscriber_userid'] = $this->userID; - $_SESSION['subscriber_typeid'] = $this->typeID; //email - $_SESSION['subscriber_token'] = $this->token; - } - - public function set_logged_off() - { - unset($_SESSION['subscriber_valid']); - unset($_SESSION['subscriber_userid']); - unset($_SESSION['subscriber_typeid']); - unset($_SESSION['subscriber_id']); - unset($_SESSION['subscriber_token']); - } - -} diff --git a/classes/subscriptions.php b/classes/subscriptions.php deleted file mode 100644 index 59507d2..0000000 --- a/classes/subscriptions.php +++ /dev/null @@ -1,94 +0,0 @@ -prepare("INSERT INTO services_subscriber (subscriberIDFK, serviceIDFK) VALUES (?, ?)"); - $stmt->bind_param("ii", $userID, $service); - $stmt->execute(); - //$query = $stmt->get_result(); - return true; - } - - public function remove($userID, $service) - { - global $mysqli; - - $stmt = $mysqli->prepare("DELETE FROM services_subscriber WHERE subscriberIDFK = ? AND serviceIDFK = ?"); - $stmt->bind_param("ii", $userID, $service); - $stmt->execute(); - //$query = $stmt->get_result(); - return true; - } - - function render_subscribed_services($typeID, $subscriberID, $userID, $token) - { - global $mysqli; - $stmt = $mysqli->prepare("SELECT services.id, services.name, subscribers.subscriberID, subscribers.userID, subscribers.token - FROM services - LEFT JOIN services_subscriber ON services_subscriber.serviceIDFK = services.id - LEFT JOIN subscribers ON services_subscriber.subscriberIDFK = subscribers.subscriberID - WHERE subscribers.typeID = ? AND subscribers.subscriberID = ?"); - $stmt->bind_param("ii", $typeID, $subscriberID); - $stmt->execute(); - $query = $stmt->get_result(); - - $strNotifyType = _('E-mail Notification subscription'); - if ( $typeID == 1 ) { $strNotifyType = _('Telegram Notification subscription'); } - - ?> - - ' . _("Your subscriptions") . ""; - echo '
        '; - $subs = array(); // Will be used to hold IDs of services already selected - - if ($query->num_rows){ - while($result = $query->fetch_assoc()) - { - echo ' ' . $result['name'] . ''; - $subs[] = $result['id']; - } - - } else { - echo '
        '._("You do not currently subscribe to any services. Please add services from the list below.").'
        '; - } - echo "
        "; - - echo '

        ' . _("Add new subscription") . '

        '; - - // Prepare to query for unselect services. If none are selected, query for all - $subsExp = null; - if (count($subs) > 0 ) { - $subsExp = 'NOT IN ('. implode(",", $subs) .')'; - } - - $query = $mysqli->query("SELECT services.id, services.name from services WHERE services.id $subsExp"); - echo '
        '; - if ($query->num_rows){ - while($result = $query->fetch_assoc()){ - echo ' ' . $result['name'] . ''; - } - } else { - echo '
        '._("No further services available for subscriptions.").'
        '; - } - echo '
        '; - } - -} \ No newline at end of file diff --git a/classes/telegram.php b/classes/telegram.php deleted file mode 100644 index 5d506c7..0000000 --- a/classes/telegram.php +++ /dev/null @@ -1,82 +0,0 @@ - $value) { - // $data_check_arr[] = $key . '=' . $value; - $data_check_arr[] = $key . '=' . str_replace('https:/t', 'https://t', $value); - } - sort($data_check_arr); - $data_check_string = implode("\n", $data_check_arr); - $secret_key = hash('sha256', TG_BOT_API_TOKEN, true); - $hash = hash_hmac('sha256', $data_check_string, $secret_key); - if (strcmp($hash, $check_hash) !== 0) { - throw new Exception('Data is NOT from Telegram'); - } - if ((time() - $auth_data['auth_date']) > 86400) { - throw new Exception('Data is outdated'); - } - return $auth_data; - } - - - /** - * Save telegram userdata - * - * Save the telegram user data in a cookie - * @return void - */ - function saveTelegramUserData($auth_data) { - $auth_data_json = json_encode($auth_data); - setcookie('tg_user', $auth_data_json); - } - - function get_telegram_subscriberid($user) - { - global $mysqli; - $stmt = $mysqli->prepare("SELECT subscriberID FROM subscribers WHERE typeID=1 AND userID LIKE ? LIMIT 1"); - $stmt->bind_param("s", $user); - $stmt->execute(); - $result = $stmt->get_result(); - if ( $result->num_rows) { - $row = $result->fetch_assoc(); - $subscriberID = $row['subscriberID']; - return $subscriberID; - } - return null; // Return null on false - } -} \ No newline at end of file diff --git a/classes/token.php b/classes/token.php deleted file mode 100644 index 1771367..0000000 --- a/classes/token.php +++ /dev/null @@ -1,74 +0,0 @@ -prepare("INSERT INTO tokens VALUES(?, ?, ?, ?)"); - $stmt->bind_param("siis", $token, $id, $expire, $data); - $stmt->execute(); - $stmt->get_result(); - return $token; - } - - /** - * Checks whether token exists in the database and has not expired. - * @param String $token - * @param int $id user ID - * @param String $data - * @return int count of results in database - */ - public static function validate($token, $id, $data) - { - global $mysqli; - $time = time(); - $stmt = $mysqli->prepare("SELECT count(*) as count FROM tokens WHERE token = ? AND user = ? AND expire>=? AND data LIKE ?"); - $stmt->bind_param("siis", $token, $id, $time, $data); - $stmt->execute(); - $query = $stmt->get_result(); - return $query->fetch_assoc()['count']; - } - - /** - * Returns token data - * @param String $token - * @param int $id user ID - * @return String data - */ - public static function get_data($token, $id) - { - global $mysqli; - $stmt = $mysqli->prepare("SELECT data as count FROM tokens WHERE token = ? AND user = ?"); - $stmt->bind_param("si", $token, $id); - $stmt->execute(); - $query = $stmt->get_result(); - return $query->fetch_assoc()['data']; - } - - /** - * Deletes token. - * @param String $token - * @return void - */ - public static function delete($token) - { - global $mysqli; - $time = time(); - $stmt = $mysqli->prepare("DELETE FROM tokens WHERE token = ? OR expirebind_param("sd", $token,$time); - $stmt->execute(); - $stmt->get_result(); - } -} \ No newline at end of file diff --git a/classes/user.php b/classes/user.php deleted file mode 100644 index f613373..0000000 --- a/classes/user.php +++ /dev/null @@ -1,739 +0,0 @@ -prepare("SELECT * FROM users WHERE id=?"); - $stmt->bind_param("d", $id); - $stmt->execute(); - $query = $stmt->get_result(); - - if (!$query->num_rows) - { - throw new Exception("User doesn't exist."); - return; - } - - $result = $query->fetch_array(); - $this->id = $id; - $this->active = $result['active']; - $this->name = $result['name']; - $this->email = $result['email']; - $this->surname = $result['surname']; - $this->username = $result['username']; - $this->rank = $result['permission']; - } - - /** - * Returns username of this user - * @return String username - */ - public function get_username() - { - return $this->username; - } - - /** - * Returns whether this user is active - * @return Boolean user active status - */ - public function is_active() - { - return $this->active; - } - - /** - * Returns rank of this user - * @return int rank - */ - public function get_rank() - { - return $this->rank; - } - - /** - * Returns full name of this user - * @return String name in "Name Surname" format - */ - public function get_name() - { - return $this->name . " " . $this->surname; - } - - /** - * Toggles active status of this user. First checks if the user - * making the change has permission to do that. - * @return void - */ - public function toggle() - { - global $mysqli, $message, $user; - - $id = $_GET['id']; - if ($this->id!=$_SESSION['user'] && $user->get_rank()<=1 && ($user->get_rank()<$this->rank)) - { - $stmt = $mysqli->prepare("UPDATE users SET active = !active WHERE id=?"); - $stmt->bind_param("i", $this->id); - $stmt->execute(); - $stmt->close(); - header("Location: ".WEB_URL."/admin/?do=user&id=".$id); - }else{ - $message = _("You don't have the permission to do that!"); - } - } - - /** - * Processes submitted form and adds user unless problem is encountered, - * calling this is possible only for Superadmin (other ranks cannot add users) - * or when the installation script is being run. Also checks requirements - * for username and email being unique and char limits. - * @return void - */ - public static function add() - { - global $user, $message, $mysqli; - if (INSTALL_OVERRIDE || $user->get_rank()==0) - { - if (strlen(trim($_POST['name']))==0) { - $messages[] = _("Name"); - } - if(strlen(trim($_POST['surname']))==0) { - $messages[] = _("Surname"); - } - if(strlen(trim($_POST['email']))==0) { - $messages[] = _("Email"); - } - if(strlen(trim($_POST['password']))==0) { - $messages[] = _("Password"); - } - if(!isset($_POST['permission'])) - { - $messages[] = _("Rank"); - } - - if (isset($messages)){ - $message = "Please enter ".implode(", ", $messages); - return; - } - - $name = $_POST['name']; - $surname = $_POST['surname']; - $username = $_POST['username']; - $email = $_POST['email']; - $pass = $_POST['password']; - - if (!filter_var($email, FILTER_VALIDATE_EMAIL)) - { - $message = "Invalid email!"; - return; - } - - $variables = array(); - if (strlen($name)>50){ - $variables[] = 'name: 50'; - } - if (strlen($surname)>50){ - $variables[] = 'surname: 50'; - } - if (strlen($username)>50){ - $variables[] = 'username: 50'; - } - if (strlen($email)>60){ - $variables[] = 'email: 60'; - } - - - if (!empty($variables)) - { - $message = _("Please mind the following character limits: "); - $message .= implode(", ", $variables); - return; - } - - $salt = uniqid(mt_rand(), true); - $hash = hash('sha256', $pass.$salt); - $permission = $_POST['permission']; - - - $stmt = $mysqli->prepare("INSERT INTO users values (NULL, ?, ?, ?, ?, ?, ?, ?, 1)"); - $stmt->bind_param("ssssssi", $email, $username, $name, $surname, $hash, $salt, $permission); - $stmt->execute(); - - if ($stmt->affected_rows==0) - { - $message = _("Username or email already used"); - return; - } - - $to = $email; - $subject = _('User account created').' - '.NAME; - $msg = sprintf(_("Hi %s!
        "."Your account has been created. You can login with your email address at %s with password %s - please change it as soon as possible."), $name." ".$surname,WEB_URL."/admin", WEB_URL."/admin", $pass); - $headers = "Content-Type: text/html; charset=utf-8 ".PHP_EOL; - $headers .= "MIME-Version: 1.0 ".PHP_EOL; - $headers .= "From: ".MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; - $headers .= "Reply-To: ".MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; - - mail($to, $subject, $msg, $headers); - if (!INSTALL_OVERRIDE) - { - header("Location: ".WEB_URL."/admin/?do=settings"); - } - } - else { - $message = _("You don't have the permission to do that!"); - } - } - - /** - * Processes submitted form and logs user in, unless the user is deactivated or wrong - * password or email has been submitted. The script doesn't let anyone know which - * field was wrong as it is not possible to verify email address from outside admin panel, - * so this actually helps with security :) - * @return void - */ - public static function login() - { - global $message, $mysqli; - if (!isset($_POST['email']) && !isset($_POST['email'])) - { - return; - } - - if ((!isset($_POST['email']) || !isset($_POST['email']))) - { - $message = _("Please fill in your email and password!"); - return; - } - $email = $_POST['email']; - $pass = $_POST['pass']; - - $stmt = $mysqli->prepare("SELECT id,password_salt as salt,active FROM users WHERE email=?"); - $stmt->bind_param("s", $email); - $stmt->execute(); - $query = $stmt->get_result(); - - if ($query->num_rows<1) - { - $message = _("Wrong email or password"); - return; - } - - $result = $query->fetch_assoc(); - $salt = $result["salt"]; - $id = $result["id"]; - $active = $result["active"]; - - if (!$active) - { - $message = _("Your account has been disabled. Please contact administrator."); - return; - } - - $hash = hash('sha256', $pass.$salt); - $stmt = $mysqli->prepare("SELECT count(*) as count FROM users WHERE id=? AND password_hash=?"); - $stmt->bind_param("is", $id, $hash); - $stmt->execute(); - $query = $stmt->get_result(); - - if (!$query->fetch_assoc()['count']) - { - $message = _("Wrong email or password"); - return; - } - - if (isset($_POST['remember'])&&$_POST['remember']) - { - $year = strtotime('+356 days', time()); - $token = Token::add($id, 'remember', $year); - setcookie('token', $token, $year, "/"); - setcookie('user', $id, $year, "/"); - } - - $_SESSION['user'] = $id; - header("Location: ".WEB_URL."/admin"); - } - - /** - * Checks whether token is valid (this means is in database and associated - * with the user) and sets session data if it is, so user remains logged in. - * The script deletes the token either way. - * @return void - */ - public static function restore_session() - { - global $message; - $id = $_COOKIE['user']; - $token = $_COOKIE['token']; - - if (Token::validate($token, $id, "remember")) - { - $year = strtotime('+356 days', time()); - unset($_COOKIE['token']); - $_SESSION['user'] = $id; - $new_token = Token::add($id, 'remember', $year); - setcookie('token', $new_token, $year, "/"); - setcookie('user', $id, $year, "/"); - } - else - { - unset($_COOKIE['user']); - unset($_COOKIE['token']); - setcookie('user', null, -1, '/'); - setcookie('token', null, -1, '/'); - $message = _("Invalid token detected, please login again!"); - } - - Token::delete($token); - } - /** - * Renders settings for this user so it can be displayed in admin panel. - * @return void - */ - public function render_user_settings() - { - global $permissions, $user; - ?> -
        -
        <?php echo _(">
        -
        - id==$_SESSION['user']||$user->get_rank()<1){ - ?> -
        -
        -
        -
        - - -
        -
        - " - title="" class="form-control form-name" - value=name, ENT_QUOTES);?>> - " - title="" class="form-control form-name" - value=surname, ENT_QUOTES);?>> -
        -
        -
        -
        - -
        -
        - -

        name." ".$this->surname;?>

        - -
        -
        -
        -
        -
        -
        - id==$_SESSION['user'] || $user->get_rank()<1){?> -
        - - - - -
        - username." "; - if ($user->get_rank()>=1){ - echo ""; - } - } - ?> -
        -
        -
        - -
        -
        -
        -
        get_rank() == 0 && $this->id != $_SESSION['user']){?> -
        - - -
        rank];}?>
        -
        -
        - - id==$_SESSION['user']||$user->get_rank()<1) - {?> -
        -
        -
        Email
        -
        -
        - - - - -
        -
        -
        -
        - -
        -
        -
        - email; ?> -
        -
        - id==$_SESSION['user']){ - ?> - -
        -
        -
        -
        - - " type="password" class="form-control" name="old_password"> - - " type="password" class="form-control" name="password"> - - " type="password" class="form-control" name="password_repeat"> - -
        -
        -
        - id!=$_SESSION['user'] && $user->get_rank()<=1 && ($user->get_rank()<$this->rank)) - {?> -
        -
        -
        - active){ - echo ''._("Deactivate user").""; - }else{ - echo ''._("Activate user").""; - } - ?> -
        -
        - id; - - $stmt = $mysqli->prepare("SELECT count(*) FROM users WHERE username LIKE ?"); - $stmt->bind_param("s",$_POST["username"]); - $stmt->execute(); - if ($stmt->num_rows > 0) - { - $message = _("This username is already taken."); - return; - } - $stmt->close(); - - if ($_SESSION['user'] != $id && $user->get_rank()>0) - { - $message = _("Cannot change username of other users!"); - }else{ - $stmt = $mysqli->prepare("UPDATE users SET username = ? WHERE id=?"); - $stmt->bind_param("si",$_POST["username"],$id); - $stmt->execute(); - $stmt->close(); - header("Location: ".WEB_URL."/admin/?do=user&id=".$id); - } - } - - /** - * Changes name and surname of user by POST[ID]. - * @return void - */ - public function change_name() - { - global $mysqli, $message, $user; - if (strlen(trim($_POST['name']))==0) { - $messages[] = _("Name"); - } - if(strlen(trim($_POST['surname']))==0) { - $messages[] = _("Surname"); - } - - if (!empty($messages)) - { - $message = "Please enter ".implode(", ", $messages); - return; - } - - $id = $this->id; - - if ($_SESSION['user'] != $id && $user->get_rank()>0) - { - $message = _("Cannot change names of other users!"); - }else{ - $stmt = $mysqli->prepare("UPDATE users SET `name` = ?, `surname` = ? WHERE id=?"); - $stmt->bind_param("ssi",$_POST["name"],$_POST["surname"],$id); - $stmt->execute(); - $stmt->close(); - header("Location: ".WEB_URL."/admin/?do=user&id=".$id); - } - } - - /** - * Changes user password and deletes all remember tokens so all other sessions - * won't stay logged in without knowing new pass. Uses token when reseting password. - * @param String $token - * @return void - */ - public function change_password($token = false) - { - global $mysqli, $message; - $id = $this->id; - if ($_POST['password']!=$_POST['password_repeat']) - { - $message = _("Passwords do not match!"); - return; - } - - if (!$token) - { - if ($_SESSION['user']!=$id) - { - $message = _("Cannot change password of other users!"); - }else{ - $stmt = $mysqli->prepare("SELECT password_salt as salt FROM users WHERE id=?"); - $stmt->bind_param("i", $id); - $stmt->execute(); - $query = $stmt->get_result(); - $result = $query->fetch_assoc(); - - $salt = $result['salt']; - $pass = $_POST['old_password']; - $hash = hash('sha256', $pass.$salt); - - $stmt = $mysqli->prepare("SELECT count(*) as count FROM users WHERE id=? AND password_hash = ?"); - $stmt->bind_param("is", $id, $hash); - $stmt->execute(); - - if ($stmt->get_result()->fetch_assoc()['count']) - { - $pass = $_POST['password']; - $hash = hash('sha256', $pass.$salt); - $stmt = $mysqli->prepare("UPDATE users SET password_hash = ? WHERE id=?"); - $stmt->bind_param("si", $hash, $id); - $stmt->execute(); - $stmt->close(); - - $stmt = $mysqli->prepare("DELETE FROM tokens WHERE user = ? AND data = 'remember'"); - $stmt->bind_param("d", $id); - $stmt->execute(); - $stmt->get_result(); - - User::logout(); - } - else{ - $message = _("Wrong password!"); - } - } - }else{ - if (Token::validate($token, $id, "passwd")) - { - $stmt = $mysqli->prepare("SELECT password_salt as salt FROM users WHERE id=?"); - $stmt->bind_param("i", $id); - $stmt->execute(); - $query = $stmt->get_result(); - $result = $query->fetch_assoc(); - - $salt = $result['salt']; - $pass = $_POST['password']; - $hash = hash('sha256', $pass.$salt); - - $stmt = $mysqli->prepare("UPDATE users SET password_hash = ? WHERE id=?"); - $stmt->bind_param("si", $hash,$id); - $stmt->execute(); - $stmt->close(); - - $stmt = $mysqli->prepare("DELETE FROM tokens WHERE user = ? AND data = 'remember'"); - $stmt->bind_param("d", $id); - $stmt->execute(); - $stmt->get_result(); - } - else - { - $message = _("Invalid token detected, please retry your request from start!"); - } - Token::delete($token); - } - } - - /** - * Sends email with link for password reset, link is token protected and valid only once. - * @return void - */ - public static function password_link() - { - global $mysqli; - $email = $_POST['email']; - - $stmt = $mysqli->prepare("SELECT id FROM users WHERE email=?"); - $stmt->bind_param("s", $email); - $stmt->execute(); - $query = $stmt->get_result(); - - $id = $query->fetch_assoc()['id']; - $time = strtotime('+1 day', time()); - - $token = Token::add($id, 'passwd', $time); - - $link = WEB_URL."/admin/?do=lost-password&id=$id&token=$token"; - $to = $email; - $user = new User($id); - $subject = _('Reset password') . ' - '.NAME; - $msg = sprintf(_( "Hi %s!
        Below you will find link to change your password. The link is valid for 24hrs. If you didn't request this, feel free to ignore it.

        RESET PASSWORD

        If the link doesn't work, copy & paste it into your browser:
        %s"), $user->get_name(), $link, $link); - $headers = "Content-Type: text/html; charset=utf-8 ".PHP_EOL; - $headers .= "MIME-Version: 1.0 ".PHP_EOL; - $headers .= "From: ".MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; - $headers .= "Reply-To: ".MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; - - mail($to, $subject, $msg, $headers); - } - - /** - * Sends email with link for email change confirmation (security reasons), link is token protected and valid only once. - * @return void - */ - public function email_link(){ - global $user, $mysqli; - - $email = $_POST['email']; - $id = $this->id; - - if ($user->get_rank()<1 && $id!=$_SESSION['user']) - { - $stmt = $mysqli->prepare("UPDATE users SET email = ? WHERE id=?"); - $stmt->bind_param("sd", $email, $id); - $stmt->execute(); - $stmt->get_result(); - header("Location: ".WEB_URL."/admin/?do=user&id=".$id); - return; - } - - $time = strtotime('+1 day', time()); - - $token = Token::add($id, 'email;$email', $time); - - $link = WEB_URL."/admin/?do=change-email&id=$id&token=$token"; - $to = $email; - $subject = _('Email change').' - '.NAME; - $msg = sprintf(_( "Hi %s!
        Below you will find link to change your email. The link is valid for 24hrs. If you didn't request this, feel free to ignore it.

        CHANGE EMAIL

        If the link doesn't work, copy & paste it into your browser:
        %s"), $user->get_name(), $link, $link); - $headers = "Content-Type: text/html; charset=utf-8 ".PHP_EOL; - $headers .= "MIME-Version: 1.0 ".PHP_EOL; - $headers .= "From: ".MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; - $headers .= "Reply-To: ".MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; - - mail($to, $subject, $msg, $headers); - return _('Confirmation email sent!'); - } - - /** - * Changes email. - * @return void - */ - public function change_email() - { - global $mysqli, $message; - $token = $_GET['token']; - $id = $_GET['id']; - - if (Token::validate($token, $id, "email;%")) - { - $data = explode(";", Token::get_data($token, $id)); - - $email = $data[1]; - - $stmt = $mysqli->prepare("UPDATE users SET email = ? WHERE id=?"); - $stmt->bind_param("sd", $email, $id); - $stmt->execute(); - $stmt->get_result(); - Token::delete($token); - header("Location: ".WEB_URL."/admin/"); - } - else - { - $message = _("Invalid token detected, please retry your request from start!"); - } - - Token::delete($token); - - } - - /** - * Logs current user out. - * @return void - */ - public static function logout(){ - session_unset(); - if (isset($_COOKIE['token'])) - { - $token = $_COOKIE['token']; - Token::delete($token); - unset($_COOKIE['user']); - unset($_COOKIE['token']); - setcookie('user', null, -1, '/'); - setcookie('token', null, -1, '/'); - } - header("Location: ".WEB_URL."/admin"); - } - - /** - * Changes permissions of current user - only super admin can do this, so it checks permission first. - * @return void - */ - public function change_permission(){ - global $mysqli, $message, $user; - if ($user->get_rank()==0) - { - $permission = $_POST['permission']; - $id = $_GET['id']; - $stmt = $mysqli->prepare("UPDATE users SET permission=? WHERE id=?"); - $stmt->bind_param("si", $permission, $id); - $stmt->execute(); - header("Location: ".WEB_URL."/admin/?do=user&id=".$id); - } - else{ - $message = _("You don't have permission to do that!"); - } - } -} diff --git a/config/config.php b/config/config.php new file mode 100644 index 0000000..9647ca1 --- /dev/null +++ b/config/config.php @@ -0,0 +1,72 @@ +negotiate($override); + $_SESSION['locale'] = $best_match; +} + +putenv('LANGUAGE='.$_SESSION['locale'].'.UTF-8'); +setlocale(LC_ALL, $_SESSION['locale'].".UTF-8"); +setlocale(LC_MESSAGES, $_SESSION['locale'].".UTF-8"); +bindtextdomain("server-status", __DIR__ . "/locale/"); +bind_textdomain_codeset("server-status", "utf-8"); +textdomain("server-status"); + +//Database connection +$mysqli = new mysqli("server-status-mysql","root","root","server-status"); + +if ($mysqli->connect_errno) { + printf(_("Connection failed: %s\n"), $mysqli->connect_error); + exit(); +} + +$mysqli->set_charset("utf8"); diff --git a/css/bootstrap.min.css b/css/bootstrap.min.css deleted file mode 100644 index 5b96335..0000000 --- a/css/bootstrap.min.css +++ /dev/null @@ -1,6 +0,0 @@ -/*! - * Bootstrap v3.4.1 (https://getbootstrap.com/) - * Copyright 2011-2019 Twitter, Inc. - * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) - *//*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background-color:transparent}a:active,a:hover{outline:0}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;-moz-text-decoration:underline dotted;text-decoration:underline dotted}b,strong{font-weight:700}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}img{border:0}svg:not(:root){overflow:hidden}figure{margin:1em 40px}hr{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;height:0}pre{overflow:auto}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}button,input,optgroup,select,textarea{color:inherit;font:inherit;margin:0}button{overflow:visible}button,select{text-transform:none}button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}input{line-height:normal}input[type=checkbox],input[type=radio]{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{height:auto}input[type=search]{-webkit-appearance:textfield;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{border:0;padding:0}textarea{overflow:auto}optgroup{font-weight:700}table{border-collapse:collapse;border-spacing:0}td,th{padding:0}/*! Source: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css */@media print{*,:after,:before{color:#000!important;text-shadow:none!important;background:0 0!important;-webkit-box-shadow:none!important;box-shadow:none!important}a,a:visited{text-decoration:underline}a[href]:after{content:" (" attr(href) ")"}abbr[title]:after{content:" (" attr(title) ")"}a[href^="#"]:after,a[href^="javascript:"]:after{content:""}blockquote,pre{border:1px solid #999;page-break-inside:avoid}thead{display:table-header-group}img,tr{page-break-inside:avoid}img{max-width:100%!important}h2,h3,p{orphans:3;widows:3}h2,h3{page-break-after:avoid}.navbar{display:none}.btn>.caret,.dropup>.btn>.caret{border-top-color:#000!important}.label{border:1px solid #000}.table{border-collapse:collapse!important}.table td,.table th{background-color:#fff!important}.table-bordered td,.table-bordered th{border:1px solid #ddd!important}}@font-face{font-family:"Glyphicons Halflings";src:url(../fonts/glyphicons-halflings-regular.eot);src:url(../fonts/glyphicons-halflings-regular.eot?#iefix) format("embedded-opentype"),url(../fonts/glyphicons-halflings-regular.woff2) format("woff2"),url(../fonts/glyphicons-halflings-regular.woff) format("woff"),url(../fonts/glyphicons-halflings-regular.ttf) format("truetype"),url(../fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular) format("svg")}.glyphicon{position:relative;top:1px;display:inline-block;font-family:"Glyphicons Halflings";font-style:normal;font-weight:400;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.glyphicon-asterisk:before{content:"\002a"}.glyphicon-plus:before{content:"\002b"}.glyphicon-eur:before,.glyphicon-euro:before{content:"\20ac"}.glyphicon-minus:before{content:"\2212"}.glyphicon-cloud:before{content:"\2601"}.glyphicon-envelope:before{content:"\2709"}.glyphicon-pencil:before{content:"\270f"}.glyphicon-glass:before{content:"\e001"}.glyphicon-music:before{content:"\e002"}.glyphicon-search:before{content:"\e003"}.glyphicon-heart:before{content:"\e005"}.glyphicon-star:before{content:"\e006"}.glyphicon-star-empty:before{content:"\e007"}.glyphicon-user:before{content:"\e008"}.glyphicon-film:before{content:"\e009"}.glyphicon-th-large:before{content:"\e010"}.glyphicon-th:before{content:"\e011"}.glyphicon-th-list:before{content:"\e012"}.glyphicon-ok:before{content:"\e013"}.glyphicon-remove:before{content:"\e014"}.glyphicon-zoom-in:before{content:"\e015"}.glyphicon-zoom-out:before{content:"\e016"}.glyphicon-off:before{content:"\e017"}.glyphicon-signal:before{content:"\e018"}.glyphicon-cog:before{content:"\e019"}.glyphicon-trash:before{content:"\e020"}.glyphicon-home:before{content:"\e021"}.glyphicon-file:before{content:"\e022"}.glyphicon-time:before{content:"\e023"}.glyphicon-road:before{content:"\e024"}.glyphicon-download-alt:before{content:"\e025"}.glyphicon-download:before{content:"\e026"}.glyphicon-upload:before{content:"\e027"}.glyphicon-inbox:before{content:"\e028"}.glyphicon-play-circle:before{content:"\e029"}.glyphicon-repeat:before{content:"\e030"}.glyphicon-refresh:before{content:"\e031"}.glyphicon-list-alt:before{content:"\e032"}.glyphicon-lock:before{content:"\e033"}.glyphicon-flag:before{content:"\e034"}.glyphicon-headphones:before{content:"\e035"}.glyphicon-volume-off:before{content:"\e036"}.glyphicon-volume-down:before{content:"\e037"}.glyphicon-volume-up:before{content:"\e038"}.glyphicon-qrcode:before{content:"\e039"}.glyphicon-barcode:before{content:"\e040"}.glyphicon-tag:before{content:"\e041"}.glyphicon-tags:before{content:"\e042"}.glyphicon-book:before{content:"\e043"}.glyphicon-bookmark:before{content:"\e044"}.glyphicon-print:before{content:"\e045"}.glyphicon-camera:before{content:"\e046"}.glyphicon-font:before{content:"\e047"}.glyphicon-bold:before{content:"\e048"}.glyphicon-italic:before{content:"\e049"}.glyphicon-text-height:before{content:"\e050"}.glyphicon-text-width:before{content:"\e051"}.glyphicon-align-left:before{content:"\e052"}.glyphicon-align-center:before{content:"\e053"}.glyphicon-align-right:before{content:"\e054"}.glyphicon-align-justify:before{content:"\e055"}.glyphicon-list:before{content:"\e056"}.glyphicon-indent-left:before{content:"\e057"}.glyphicon-indent-right:before{content:"\e058"}.glyphicon-facetime-video:before{content:"\e059"}.glyphicon-picture:before{content:"\e060"}.glyphicon-map-marker:before{content:"\e062"}.glyphicon-adjust:before{content:"\e063"}.glyphicon-tint:before{content:"\e064"}.glyphicon-edit:before{content:"\e065"}.glyphicon-share:before{content:"\e066"}.glyphicon-check:before{content:"\e067"}.glyphicon-move:before{content:"\e068"}.glyphicon-step-backward:before{content:"\e069"}.glyphicon-fast-backward:before{content:"\e070"}.glyphicon-backward:before{content:"\e071"}.glyphicon-play:before{content:"\e072"}.glyphicon-pause:before{content:"\e073"}.glyphicon-stop:before{content:"\e074"}.glyphicon-forward:before{content:"\e075"}.glyphicon-fast-forward:before{content:"\e076"}.glyphicon-step-forward:before{content:"\e077"}.glyphicon-eject:before{content:"\e078"}.glyphicon-chevron-left:before{content:"\e079"}.glyphicon-chevron-right:before{content:"\e080"}.glyphicon-plus-sign:before{content:"\e081"}.glyphicon-minus-sign:before{content:"\e082"}.glyphicon-remove-sign:before{content:"\e083"}.glyphicon-ok-sign:before{content:"\e084"}.glyphicon-question-sign:before{content:"\e085"}.glyphicon-info-sign:before{content:"\e086"}.glyphicon-screenshot:before{content:"\e087"}.glyphicon-remove-circle:before{content:"\e088"}.glyphicon-ok-circle:before{content:"\e089"}.glyphicon-ban-circle:before{content:"\e090"}.glyphicon-arrow-left:before{content:"\e091"}.glyphicon-arrow-right:before{content:"\e092"}.glyphicon-arrow-up:before{content:"\e093"}.glyphicon-arrow-down:before{content:"\e094"}.glyphicon-share-alt:before{content:"\e095"}.glyphicon-resize-full:before{content:"\e096"}.glyphicon-resize-small:before{content:"\e097"}.glyphicon-exclamation-sign:before{content:"\e101"}.glyphicon-gift:before{content:"\e102"}.glyphicon-leaf:before{content:"\e103"}.glyphicon-fire:before{content:"\e104"}.glyphicon-eye-open:before{content:"\e105"}.glyphicon-eye-close:before{content:"\e106"}.glyphicon-warning-sign:before{content:"\e107"}.glyphicon-plane:before{content:"\e108"}.glyphicon-calendar:before{content:"\e109"}.glyphicon-random:before{content:"\e110"}.glyphicon-comment:before{content:"\e111"}.glyphicon-magnet:before{content:"\e112"}.glyphicon-chevron-up:before{content:"\e113"}.glyphicon-chevron-down:before{content:"\e114"}.glyphicon-retweet:before{content:"\e115"}.glyphicon-shopping-cart:before{content:"\e116"}.glyphicon-folder-close:before{content:"\e117"}.glyphicon-folder-open:before{content:"\e118"}.glyphicon-resize-vertical:before{content:"\e119"}.glyphicon-resize-horizontal:before{content:"\e120"}.glyphicon-hdd:before{content:"\e121"}.glyphicon-bullhorn:before{content:"\e122"}.glyphicon-bell:before{content:"\e123"}.glyphicon-certificate:before{content:"\e124"}.glyphicon-thumbs-up:before{content:"\e125"}.glyphicon-thumbs-down:before{content:"\e126"}.glyphicon-hand-right:before{content:"\e127"}.glyphicon-hand-left:before{content:"\e128"}.glyphicon-hand-up:before{content:"\e129"}.glyphicon-hand-down:before{content:"\e130"}.glyphicon-circle-arrow-right:before{content:"\e131"}.glyphicon-circle-arrow-left:before{content:"\e132"}.glyphicon-circle-arrow-up:before{content:"\e133"}.glyphicon-circle-arrow-down:before{content:"\e134"}.glyphicon-globe:before{content:"\e135"}.glyphicon-wrench:before{content:"\e136"}.glyphicon-tasks:before{content:"\e137"}.glyphicon-filter:before{content:"\e138"}.glyphicon-briefcase:before{content:"\e139"}.glyphicon-fullscreen:before{content:"\e140"}.glyphicon-dashboard:before{content:"\e141"}.glyphicon-paperclip:before{content:"\e142"}.glyphicon-heart-empty:before{content:"\e143"}.glyphicon-link:before{content:"\e144"}.glyphicon-phone:before{content:"\e145"}.glyphicon-pushpin:before{content:"\e146"}.glyphicon-usd:before{content:"\e148"}.glyphicon-gbp:before{content:"\e149"}.glyphicon-sort:before{content:"\e150"}.glyphicon-sort-by-alphabet:before{content:"\e151"}.glyphicon-sort-by-alphabet-alt:before{content:"\e152"}.glyphicon-sort-by-order:before{content:"\e153"}.glyphicon-sort-by-order-alt:before{content:"\e154"}.glyphicon-sort-by-attributes:before{content:"\e155"}.glyphicon-sort-by-attributes-alt:before{content:"\e156"}.glyphicon-unchecked:before{content:"\e157"}.glyphicon-expand:before{content:"\e158"}.glyphicon-collapse-down:before{content:"\e159"}.glyphicon-collapse-up:before{content:"\e160"}.glyphicon-log-in:before{content:"\e161"}.glyphicon-flash:before{content:"\e162"}.glyphicon-log-out:before{content:"\e163"}.glyphicon-new-window:before{content:"\e164"}.glyphicon-record:before{content:"\e165"}.glyphicon-save:before{content:"\e166"}.glyphicon-open:before{content:"\e167"}.glyphicon-saved:before{content:"\e168"}.glyphicon-import:before{content:"\e169"}.glyphicon-export:before{content:"\e170"}.glyphicon-send:before{content:"\e171"}.glyphicon-floppy-disk:before{content:"\e172"}.glyphicon-floppy-saved:before{content:"\e173"}.glyphicon-floppy-remove:before{content:"\e174"}.glyphicon-floppy-save:before{content:"\e175"}.glyphicon-floppy-open:before{content:"\e176"}.glyphicon-credit-card:before{content:"\e177"}.glyphicon-transfer:before{content:"\e178"}.glyphicon-cutlery:before{content:"\e179"}.glyphicon-header:before{content:"\e180"}.glyphicon-compressed:before{content:"\e181"}.glyphicon-earphone:before{content:"\e182"}.glyphicon-phone-alt:before{content:"\e183"}.glyphicon-tower:before{content:"\e184"}.glyphicon-stats:before{content:"\e185"}.glyphicon-sd-video:before{content:"\e186"}.glyphicon-hd-video:before{content:"\e187"}.glyphicon-subtitles:before{content:"\e188"}.glyphicon-sound-stereo:before{content:"\e189"}.glyphicon-sound-dolby:before{content:"\e190"}.glyphicon-sound-5-1:before{content:"\e191"}.glyphicon-sound-6-1:before{content:"\e192"}.glyphicon-sound-7-1:before{content:"\e193"}.glyphicon-copyright-mark:before{content:"\e194"}.glyphicon-registration-mark:before{content:"\e195"}.glyphicon-cloud-download:before{content:"\e197"}.glyphicon-cloud-upload:before{content:"\e198"}.glyphicon-tree-conifer:before{content:"\e199"}.glyphicon-tree-deciduous:before{content:"\e200"}.glyphicon-cd:before{content:"\e201"}.glyphicon-save-file:before{content:"\e202"}.glyphicon-open-file:before{content:"\e203"}.glyphicon-level-up:before{content:"\e204"}.glyphicon-copy:before{content:"\e205"}.glyphicon-paste:before{content:"\e206"}.glyphicon-alert:before{content:"\e209"}.glyphicon-equalizer:before{content:"\e210"}.glyphicon-king:before{content:"\e211"}.glyphicon-queen:before{content:"\e212"}.glyphicon-pawn:before{content:"\e213"}.glyphicon-bishop:before{content:"\e214"}.glyphicon-knight:before{content:"\e215"}.glyphicon-baby-formula:before{content:"\e216"}.glyphicon-tent:before{content:"\26fa"}.glyphicon-blackboard:before{content:"\e218"}.glyphicon-bed:before{content:"\e219"}.glyphicon-apple:before{content:"\f8ff"}.glyphicon-erase:before{content:"\e221"}.glyphicon-hourglass:before{content:"\231b"}.glyphicon-lamp:before{content:"\e223"}.glyphicon-duplicate:before{content:"\e224"}.glyphicon-piggy-bank:before{content:"\e225"}.glyphicon-scissors:before{content:"\e226"}.glyphicon-bitcoin:before{content:"\e227"}.glyphicon-btc:before{content:"\e227"}.glyphicon-xbt:before{content:"\e227"}.glyphicon-yen:before{content:"\00a5"}.glyphicon-jpy:before{content:"\00a5"}.glyphicon-ruble:before{content:"\20bd"}.glyphicon-rub:before{content:"\20bd"}.glyphicon-scale:before{content:"\e230"}.glyphicon-ice-lolly:before{content:"\e231"}.glyphicon-ice-lolly-tasted:before{content:"\e232"}.glyphicon-education:before{content:"\e233"}.glyphicon-option-horizontal:before{content:"\e234"}.glyphicon-option-vertical:before{content:"\e235"}.glyphicon-menu-hamburger:before{content:"\e236"}.glyphicon-modal-window:before{content:"\e237"}.glyphicon-oil:before{content:"\e238"}.glyphicon-grain:before{content:"\e239"}.glyphicon-sunglasses:before{content:"\e240"}.glyphicon-text-size:before{content:"\e241"}.glyphicon-text-color:before{content:"\e242"}.glyphicon-text-background:before{content:"\e243"}.glyphicon-object-align-top:before{content:"\e244"}.glyphicon-object-align-bottom:before{content:"\e245"}.glyphicon-object-align-horizontal:before{content:"\e246"}.glyphicon-object-align-left:before{content:"\e247"}.glyphicon-object-align-vertical:before{content:"\e248"}.glyphicon-object-align-right:before{content:"\e249"}.glyphicon-triangle-right:before{content:"\e250"}.glyphicon-triangle-left:before{content:"\e251"}.glyphicon-triangle-bottom:before{content:"\e252"}.glyphicon-triangle-top:before{content:"\e253"}.glyphicon-console:before{content:"\e254"}.glyphicon-superscript:before{content:"\e255"}.glyphicon-subscript:before{content:"\e256"}.glyphicon-menu-left:before{content:"\e257"}.glyphicon-menu-right:before{content:"\e258"}.glyphicon-menu-down:before{content:"\e259"}.glyphicon-menu-up:before{content:"\e260"}*{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}:after,:before{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}html{font-size:10px;-webkit-tap-highlight-color:rgba(0,0,0,0)}body{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:1.42857143;color:#333;background-color:#fff}button,input,select,textarea{font-family:inherit;font-size:inherit;line-height:inherit}a{color:#337ab7;text-decoration:none}a:focus,a:hover{color:#23527c;text-decoration:underline}a:focus{outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}figure{margin:0}img{vertical-align:middle}.carousel-inner>.item>a>img,.carousel-inner>.item>img,.img-responsive,.thumbnail a>img,.thumbnail>img{display:block;max-width:100%;height:auto}.img-rounded{border-radius:6px}.img-thumbnail{padding:4px;line-height:1.42857143;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:all .2s ease-in-out;-o-transition:all .2s ease-in-out;transition:all .2s ease-in-out;display:inline-block;max-width:100%;height:auto}.img-circle{border-radius:50%}hr{margin-top:20px;margin-bottom:20px;border:0;border-top:1px solid #eee}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto}[role=button]{cursor:pointer}.h1,.h2,.h3,.h4,.h5,.h6,h1,h2,h3,h4,h5,h6{font-family:inherit;font-weight:500;line-height:1.1;color:inherit}.h1 .small,.h1 small,.h2 .small,.h2 small,.h3 .small,.h3 small,.h4 .small,.h4 small,.h5 .small,.h5 small,.h6 .small,.h6 small,h1 .small,h1 small,h2 .small,h2 small,h3 .small,h3 small,h4 .small,h4 small,h5 .small,h5 small,h6 .small,h6 small{font-weight:400;line-height:1;color:#777}.h1,.h2,.h3,h1,h2,h3{margin-top:20px;margin-bottom:10px}.h1 .small,.h1 small,.h2 .small,.h2 small,.h3 .small,.h3 small,h1 .small,h1 small,h2 .small,h2 small,h3 .small,h3 small{font-size:65%}.h4,.h5,.h6,h4,h5,h6{margin-top:10px;margin-bottom:10px}.h4 .small,.h4 small,.h5 .small,.h5 small,.h6 .small,.h6 small,h4 .small,h4 small,h5 .small,h5 small,h6 .small,h6 small{font-size:75%}.h1,h1{font-size:36px}.h2,h2{font-size:30px}.h3,h3{font-size:24px}.h4,h4{font-size:18px}.h5,h5{font-size:14px}.h6,h6{font-size:12px}p{margin:0 0 10px}.lead{margin-bottom:20px;font-size:16px;font-weight:300;line-height:1.4}@media (min-width:768px){.lead{font-size:21px}}.small,small{font-size:85%}.mark,mark{padding:.2em;background-color:#fcf8e3}.text-left{text-align:left}.text-right{text-align:right}.text-center{text-align:center}.text-justify{text-align:justify}.text-nowrap{white-space:nowrap}.text-lowercase{text-transform:lowercase}.text-uppercase{text-transform:uppercase}.text-capitalize{text-transform:capitalize}.text-muted{color:#777}.text-primary{color:#337ab7}a.text-primary:focus,a.text-primary:hover{color:#286090}.text-success{color:#3c763d}a.text-success:focus,a.text-success:hover{color:#2b542c}.text-info{color:#31708f}a.text-info:focus,a.text-info:hover{color:#245269}.text-warning{color:#8a6d3b}a.text-warning:focus,a.text-warning:hover{color:#66512c}.text-danger{color:#a94442}a.text-danger:focus,a.text-danger:hover{color:#843534}.bg-primary{color:#fff;background-color:#337ab7}a.bg-primary:focus,a.bg-primary:hover{background-color:#286090}.bg-success{background-color:#dff0d8}a.bg-success:focus,a.bg-success:hover{background-color:#c1e2b3}.bg-info{background-color:#d9edf7}a.bg-info:focus,a.bg-info:hover{background-color:#afd9ee}.bg-warning{background-color:#fcf8e3}a.bg-warning:focus,a.bg-warning:hover{background-color:#f7ecb5}.bg-danger{background-color:#f2dede}a.bg-danger:focus,a.bg-danger:hover{background-color:#e4b9b9}.page-header{padding-bottom:9px;margin:40px 0 20px;border-bottom:1px solid #eee}ol,ul{margin-top:0;margin-bottom:10px}ol ol,ol ul,ul ol,ul ul{margin-bottom:0}.list-unstyled{padding-left:0;list-style:none}.list-inline{padding-left:0;list-style:none;margin-left:-5px}.list-inline>li{display:inline-block;padding-right:5px;padding-left:5px}dl{margin-top:0;margin-bottom:20px}dd,dt{line-height:1.42857143}dt{font-weight:700}dd{margin-left:0}@media (min-width:768px){.dl-horizontal dt{float:left;width:160px;clear:left;text-align:right;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.dl-horizontal dd{margin-left:180px}}abbr[data-original-title],abbr[title]{cursor:help}.initialism{font-size:90%;text-transform:uppercase}blockquote{padding:10px 20px;margin:0 0 20px;font-size:17.5px;border-left:5px solid #eee}blockquote ol:last-child,blockquote p:last-child,blockquote ul:last-child{margin-bottom:0}blockquote .small,blockquote footer,blockquote small{display:block;font-size:80%;line-height:1.42857143;color:#777}blockquote .small:before,blockquote footer:before,blockquote small:before{content:"\2014 \00A0"}.blockquote-reverse,blockquote.pull-right{padding-right:15px;padding-left:0;text-align:right;border-right:5px solid #eee;border-left:0}.blockquote-reverse .small:before,.blockquote-reverse footer:before,.blockquote-reverse small:before,blockquote.pull-right .small:before,blockquote.pull-right footer:before,blockquote.pull-right small:before{content:""}.blockquote-reverse .small:after,.blockquote-reverse footer:after,.blockquote-reverse small:after,blockquote.pull-right .small:after,blockquote.pull-right footer:after,blockquote.pull-right small:after{content:"\00A0 \2014"}address{margin-bottom:20px;font-style:normal;line-height:1.42857143}code,kbd,pre,samp{font-family:Menlo,Monaco,Consolas,"Courier New",monospace}code{padding:2px 4px;font-size:90%;color:#c7254e;background-color:#f9f2f4;border-radius:4px}kbd{padding:2px 4px;font-size:90%;color:#fff;background-color:#333;border-radius:3px;-webkit-box-shadow:inset 0 -1px 0 rgba(0,0,0,.25);box-shadow:inset 0 -1px 0 rgba(0,0,0,.25)}kbd kbd{padding:0;font-size:100%;font-weight:700;-webkit-box-shadow:none;box-shadow:none}pre{display:block;padding:9.5px;margin:0 0 10px;font-size:13px;line-height:1.42857143;color:#333;word-break:break-all;word-wrap:break-word;background-color:#f5f5f5;border:1px solid #ccc;border-radius:4px}pre code{padding:0;font-size:inherit;color:inherit;white-space:pre-wrap;background-color:transparent;border-radius:0}.pre-scrollable{max-height:340px;overflow-y:scroll}.container{padding-right:15px;padding-left:15px;margin-right:auto;margin-left:auto}@media (min-width:768px){.container{width:750px}}@media (min-width:992px){.container{width:970px}}@media (min-width:1200px){.container{width:1170px}}.container-fluid{padding-right:15px;padding-left:15px;margin-right:auto;margin-left:auto}.row{margin-right:-15px;margin-left:-15px}.row-no-gutters{margin-right:0;margin-left:0}.row-no-gutters [class*=col-]{padding-right:0;padding-left:0}.col-lg-1,.col-lg-10,.col-lg-11,.col-lg-12,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,.col-lg-7,.col-lg-8,.col-lg-9,.col-md-1,.col-md-10,.col-md-11,.col-md-12,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,.col-md-7,.col-md-8,.col-md-9,.col-sm-1,.col-sm-10,.col-sm-11,.col-sm-12,.col-sm-2,.col-sm-3,.col-sm-4,.col-sm-5,.col-sm-6,.col-sm-7,.col-sm-8,.col-sm-9,.col-xs-1,.col-xs-10,.col-xs-11,.col-xs-12,.col-xs-2,.col-xs-3,.col-xs-4,.col-xs-5,.col-xs-6,.col-xs-7,.col-xs-8,.col-xs-9{position:relative;min-height:1px;padding-right:15px;padding-left:15px}.col-xs-1,.col-xs-10,.col-xs-11,.col-xs-12,.col-xs-2,.col-xs-3,.col-xs-4,.col-xs-5,.col-xs-6,.col-xs-7,.col-xs-8,.col-xs-9{float:left}.col-xs-12{width:100%}.col-xs-11{width:91.66666667%}.col-xs-10{width:83.33333333%}.col-xs-9{width:75%}.col-xs-8{width:66.66666667%}.col-xs-7{width:58.33333333%}.col-xs-6{width:50%}.col-xs-5{width:41.66666667%}.col-xs-4{width:33.33333333%}.col-xs-3{width:25%}.col-xs-2{width:16.66666667%}.col-xs-1{width:8.33333333%}.col-xs-pull-12{right:100%}.col-xs-pull-11{right:91.66666667%}.col-xs-pull-10{right:83.33333333%}.col-xs-pull-9{right:75%}.col-xs-pull-8{right:66.66666667%}.col-xs-pull-7{right:58.33333333%}.col-xs-pull-6{right:50%}.col-xs-pull-5{right:41.66666667%}.col-xs-pull-4{right:33.33333333%}.col-xs-pull-3{right:25%}.col-xs-pull-2{right:16.66666667%}.col-xs-pull-1{right:8.33333333%}.col-xs-pull-0{right:auto}.col-xs-push-12{left:100%}.col-xs-push-11{left:91.66666667%}.col-xs-push-10{left:83.33333333%}.col-xs-push-9{left:75%}.col-xs-push-8{left:66.66666667%}.col-xs-push-7{left:58.33333333%}.col-xs-push-6{left:50%}.col-xs-push-5{left:41.66666667%}.col-xs-push-4{left:33.33333333%}.col-xs-push-3{left:25%}.col-xs-push-2{left:16.66666667%}.col-xs-push-1{left:8.33333333%}.col-xs-push-0{left:auto}.col-xs-offset-12{margin-left:100%}.col-xs-offset-11{margin-left:91.66666667%}.col-xs-offset-10{margin-left:83.33333333%}.col-xs-offset-9{margin-left:75%}.col-xs-offset-8{margin-left:66.66666667%}.col-xs-offset-7{margin-left:58.33333333%}.col-xs-offset-6{margin-left:50%}.col-xs-offset-5{margin-left:41.66666667%}.col-xs-offset-4{margin-left:33.33333333%}.col-xs-offset-3{margin-left:25%}.col-xs-offset-2{margin-left:16.66666667%}.col-xs-offset-1{margin-left:8.33333333%}.col-xs-offset-0{margin-left:0}@media (min-width:768px){.col-sm-1,.col-sm-10,.col-sm-11,.col-sm-12,.col-sm-2,.col-sm-3,.col-sm-4,.col-sm-5,.col-sm-6,.col-sm-7,.col-sm-8,.col-sm-9{float:left}.col-sm-12{width:100%}.col-sm-11{width:91.66666667%}.col-sm-10{width:83.33333333%}.col-sm-9{width:75%}.col-sm-8{width:66.66666667%}.col-sm-7{width:58.33333333%}.col-sm-6{width:50%}.col-sm-5{width:41.66666667%}.col-sm-4{width:33.33333333%}.col-sm-3{width:25%}.col-sm-2{width:16.66666667%}.col-sm-1{width:8.33333333%}.col-sm-pull-12{right:100%}.col-sm-pull-11{right:91.66666667%}.col-sm-pull-10{right:83.33333333%}.col-sm-pull-9{right:75%}.col-sm-pull-8{right:66.66666667%}.col-sm-pull-7{right:58.33333333%}.col-sm-pull-6{right:50%}.col-sm-pull-5{right:41.66666667%}.col-sm-pull-4{right:33.33333333%}.col-sm-pull-3{right:25%}.col-sm-pull-2{right:16.66666667%}.col-sm-pull-1{right:8.33333333%}.col-sm-pull-0{right:auto}.col-sm-push-12{left:100%}.col-sm-push-11{left:91.66666667%}.col-sm-push-10{left:83.33333333%}.col-sm-push-9{left:75%}.col-sm-push-8{left:66.66666667%}.col-sm-push-7{left:58.33333333%}.col-sm-push-6{left:50%}.col-sm-push-5{left:41.66666667%}.col-sm-push-4{left:33.33333333%}.col-sm-push-3{left:25%}.col-sm-push-2{left:16.66666667%}.col-sm-push-1{left:8.33333333%}.col-sm-push-0{left:auto}.col-sm-offset-12{margin-left:100%}.col-sm-offset-11{margin-left:91.66666667%}.col-sm-offset-10{margin-left:83.33333333%}.col-sm-offset-9{margin-left:75%}.col-sm-offset-8{margin-left:66.66666667%}.col-sm-offset-7{margin-left:58.33333333%}.col-sm-offset-6{margin-left:50%}.col-sm-offset-5{margin-left:41.66666667%}.col-sm-offset-4{margin-left:33.33333333%}.col-sm-offset-3{margin-left:25%}.col-sm-offset-2{margin-left:16.66666667%}.col-sm-offset-1{margin-left:8.33333333%}.col-sm-offset-0{margin-left:0}}@media (min-width:992px){.col-md-1,.col-md-10,.col-md-11,.col-md-12,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,.col-md-7,.col-md-8,.col-md-9{float:left}.col-md-12{width:100%}.col-md-11{width:91.66666667%}.col-md-10{width:83.33333333%}.col-md-9{width:75%}.col-md-8{width:66.66666667%}.col-md-7{width:58.33333333%}.col-md-6{width:50%}.col-md-5{width:41.66666667%}.col-md-4{width:33.33333333%}.col-md-3{width:25%}.col-md-2{width:16.66666667%}.col-md-1{width:8.33333333%}.col-md-pull-12{right:100%}.col-md-pull-11{right:91.66666667%}.col-md-pull-10{right:83.33333333%}.col-md-pull-9{right:75%}.col-md-pull-8{right:66.66666667%}.col-md-pull-7{right:58.33333333%}.col-md-pull-6{right:50%}.col-md-pull-5{right:41.66666667%}.col-md-pull-4{right:33.33333333%}.col-md-pull-3{right:25%}.col-md-pull-2{right:16.66666667%}.col-md-pull-1{right:8.33333333%}.col-md-pull-0{right:auto}.col-md-push-12{left:100%}.col-md-push-11{left:91.66666667%}.col-md-push-10{left:83.33333333%}.col-md-push-9{left:75%}.col-md-push-8{left:66.66666667%}.col-md-push-7{left:58.33333333%}.col-md-push-6{left:50%}.col-md-push-5{left:41.66666667%}.col-md-push-4{left:33.33333333%}.col-md-push-3{left:25%}.col-md-push-2{left:16.66666667%}.col-md-push-1{left:8.33333333%}.col-md-push-0{left:auto}.col-md-offset-12{margin-left:100%}.col-md-offset-11{margin-left:91.66666667%}.col-md-offset-10{margin-left:83.33333333%}.col-md-offset-9{margin-left:75%}.col-md-offset-8{margin-left:66.66666667%}.col-md-offset-7{margin-left:58.33333333%}.col-md-offset-6{margin-left:50%}.col-md-offset-5{margin-left:41.66666667%}.col-md-offset-4{margin-left:33.33333333%}.col-md-offset-3{margin-left:25%}.col-md-offset-2{margin-left:16.66666667%}.col-md-offset-1{margin-left:8.33333333%}.col-md-offset-0{margin-left:0}}@media (min-width:1200px){.col-lg-1,.col-lg-10,.col-lg-11,.col-lg-12,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,.col-lg-7,.col-lg-8,.col-lg-9{float:left}.col-lg-12{width:100%}.col-lg-11{width:91.66666667%}.col-lg-10{width:83.33333333%}.col-lg-9{width:75%}.col-lg-8{width:66.66666667%}.col-lg-7{width:58.33333333%}.col-lg-6{width:50%}.col-lg-5{width:41.66666667%}.col-lg-4{width:33.33333333%}.col-lg-3{width:25%}.col-lg-2{width:16.66666667%}.col-lg-1{width:8.33333333%}.col-lg-pull-12{right:100%}.col-lg-pull-11{right:91.66666667%}.col-lg-pull-10{right:83.33333333%}.col-lg-pull-9{right:75%}.col-lg-pull-8{right:66.66666667%}.col-lg-pull-7{right:58.33333333%}.col-lg-pull-6{right:50%}.col-lg-pull-5{right:41.66666667%}.col-lg-pull-4{right:33.33333333%}.col-lg-pull-3{right:25%}.col-lg-pull-2{right:16.66666667%}.col-lg-pull-1{right:8.33333333%}.col-lg-pull-0{right:auto}.col-lg-push-12{left:100%}.col-lg-push-11{left:91.66666667%}.col-lg-push-10{left:83.33333333%}.col-lg-push-9{left:75%}.col-lg-push-8{left:66.66666667%}.col-lg-push-7{left:58.33333333%}.col-lg-push-6{left:50%}.col-lg-push-5{left:41.66666667%}.col-lg-push-4{left:33.33333333%}.col-lg-push-3{left:25%}.col-lg-push-2{left:16.66666667%}.col-lg-push-1{left:8.33333333%}.col-lg-push-0{left:auto}.col-lg-offset-12{margin-left:100%}.col-lg-offset-11{margin-left:91.66666667%}.col-lg-offset-10{margin-left:83.33333333%}.col-lg-offset-9{margin-left:75%}.col-lg-offset-8{margin-left:66.66666667%}.col-lg-offset-7{margin-left:58.33333333%}.col-lg-offset-6{margin-left:50%}.col-lg-offset-5{margin-left:41.66666667%}.col-lg-offset-4{margin-left:33.33333333%}.col-lg-offset-3{margin-left:25%}.col-lg-offset-2{margin-left:16.66666667%}.col-lg-offset-1{margin-left:8.33333333%}.col-lg-offset-0{margin-left:0}}table{background-color:transparent}table col[class*=col-]{position:static;display:table-column;float:none}table td[class*=col-],table th[class*=col-]{position:static;display:table-cell;float:none}caption{padding-top:8px;padding-bottom:8px;color:#777;text-align:left}th{text-align:left}.table{width:100%;max-width:100%;margin-bottom:20px}.table>tbody>tr>td,.table>tbody>tr>th,.table>tfoot>tr>td,.table>tfoot>tr>th,.table>thead>tr>td,.table>thead>tr>th{padding:8px;line-height:1.42857143;vertical-align:top;border-top:1px solid #ddd}.table>thead>tr>th{vertical-align:bottom;border-bottom:2px solid #ddd}.table>caption+thead>tr:first-child>td,.table>caption+thead>tr:first-child>th,.table>colgroup+thead>tr:first-child>td,.table>colgroup+thead>tr:first-child>th,.table>thead:first-child>tr:first-child>td,.table>thead:first-child>tr:first-child>th{border-top:0}.table>tbody+tbody{border-top:2px solid #ddd}.table .table{background-color:#fff}.table-condensed>tbody>tr>td,.table-condensed>tbody>tr>th,.table-condensed>tfoot>tr>td,.table-condensed>tfoot>tr>th,.table-condensed>thead>tr>td,.table-condensed>thead>tr>th{padding:5px}.table-bordered{border:1px solid #ddd}.table-bordered>tbody>tr>td,.table-bordered>tbody>tr>th,.table-bordered>tfoot>tr>td,.table-bordered>tfoot>tr>th,.table-bordered>thead>tr>td,.table-bordered>thead>tr>th{border:1px solid #ddd}.table-bordered>thead>tr>td,.table-bordered>thead>tr>th{border-bottom-width:2px}.table-striped>tbody>tr:nth-of-type(odd){background-color:#f9f9f9}.table-hover>tbody>tr:hover{background-color:#f5f5f5}.table>tbody>tr.active>td,.table>tbody>tr.active>th,.table>tbody>tr>td.active,.table>tbody>tr>th.active,.table>tfoot>tr.active>td,.table>tfoot>tr.active>th,.table>tfoot>tr>td.active,.table>tfoot>tr>th.active,.table>thead>tr.active>td,.table>thead>tr.active>th,.table>thead>tr>td.active,.table>thead>tr>th.active{background-color:#f5f5f5}.table-hover>tbody>tr.active:hover>td,.table-hover>tbody>tr.active:hover>th,.table-hover>tbody>tr:hover>.active,.table-hover>tbody>tr>td.active:hover,.table-hover>tbody>tr>th.active:hover{background-color:#e8e8e8}.table>tbody>tr.success>td,.table>tbody>tr.success>th,.table>tbody>tr>td.success,.table>tbody>tr>th.success,.table>tfoot>tr.success>td,.table>tfoot>tr.success>th,.table>tfoot>tr>td.success,.table>tfoot>tr>th.success,.table>thead>tr.success>td,.table>thead>tr.success>th,.table>thead>tr>td.success,.table>thead>tr>th.success{background-color:#dff0d8}.table-hover>tbody>tr.success:hover>td,.table-hover>tbody>tr.success:hover>th,.table-hover>tbody>tr:hover>.success,.table-hover>tbody>tr>td.success:hover,.table-hover>tbody>tr>th.success:hover{background-color:#d0e9c6}.table>tbody>tr.info>td,.table>tbody>tr.info>th,.table>tbody>tr>td.info,.table>tbody>tr>th.info,.table>tfoot>tr.info>td,.table>tfoot>tr.info>th,.table>tfoot>tr>td.info,.table>tfoot>tr>th.info,.table>thead>tr.info>td,.table>thead>tr.info>th,.table>thead>tr>td.info,.table>thead>tr>th.info{background-color:#d9edf7}.table-hover>tbody>tr.info:hover>td,.table-hover>tbody>tr.info:hover>th,.table-hover>tbody>tr:hover>.info,.table-hover>tbody>tr>td.info:hover,.table-hover>tbody>tr>th.info:hover{background-color:#c4e3f3}.table>tbody>tr.warning>td,.table>tbody>tr.warning>th,.table>tbody>tr>td.warning,.table>tbody>tr>th.warning,.table>tfoot>tr.warning>td,.table>tfoot>tr.warning>th,.table>tfoot>tr>td.warning,.table>tfoot>tr>th.warning,.table>thead>tr.warning>td,.table>thead>tr.warning>th,.table>thead>tr>td.warning,.table>thead>tr>th.warning{background-color:#fcf8e3}.table-hover>tbody>tr.warning:hover>td,.table-hover>tbody>tr.warning:hover>th,.table-hover>tbody>tr:hover>.warning,.table-hover>tbody>tr>td.warning:hover,.table-hover>tbody>tr>th.warning:hover{background-color:#faf2cc}.table>tbody>tr.danger>td,.table>tbody>tr.danger>th,.table>tbody>tr>td.danger,.table>tbody>tr>th.danger,.table>tfoot>tr.danger>td,.table>tfoot>tr.danger>th,.table>tfoot>tr>td.danger,.table>tfoot>tr>th.danger,.table>thead>tr.danger>td,.table>thead>tr.danger>th,.table>thead>tr>td.danger,.table>thead>tr>th.danger{background-color:#f2dede}.table-hover>tbody>tr.danger:hover>td,.table-hover>tbody>tr.danger:hover>th,.table-hover>tbody>tr:hover>.danger,.table-hover>tbody>tr>td.danger:hover,.table-hover>tbody>tr>th.danger:hover{background-color:#ebcccc}.table-responsive{min-height:.01%;overflow-x:auto}@media screen and (max-width:767px){.table-responsive{width:100%;margin-bottom:15px;overflow-y:hidden;-ms-overflow-style:-ms-autohiding-scrollbar;border:1px solid #ddd}.table-responsive>.table{margin-bottom:0}.table-responsive>.table>tbody>tr>td,.table-responsive>.table>tbody>tr>th,.table-responsive>.table>tfoot>tr>td,.table-responsive>.table>tfoot>tr>th,.table-responsive>.table>thead>tr>td,.table-responsive>.table>thead>tr>th{white-space:nowrap}.table-responsive>.table-bordered{border:0}.table-responsive>.table-bordered>tbody>tr>td:first-child,.table-responsive>.table-bordered>tbody>tr>th:first-child,.table-responsive>.table-bordered>tfoot>tr>td:first-child,.table-responsive>.table-bordered>tfoot>tr>th:first-child,.table-responsive>.table-bordered>thead>tr>td:first-child,.table-responsive>.table-bordered>thead>tr>th:first-child{border-left:0}.table-responsive>.table-bordered>tbody>tr>td:last-child,.table-responsive>.table-bordered>tbody>tr>th:last-child,.table-responsive>.table-bordered>tfoot>tr>td:last-child,.table-responsive>.table-bordered>tfoot>tr>th:last-child,.table-responsive>.table-bordered>thead>tr>td:last-child,.table-responsive>.table-bordered>thead>tr>th:last-child{border-right:0}.table-responsive>.table-bordered>tbody>tr:last-child>td,.table-responsive>.table-bordered>tbody>tr:last-child>th,.table-responsive>.table-bordered>tfoot>tr:last-child>td,.table-responsive>.table-bordered>tfoot>tr:last-child>th{border-bottom:0}}fieldset{min-width:0;padding:0;margin:0;border:0}legend{display:block;width:100%;padding:0;margin-bottom:20px;font-size:21px;line-height:inherit;color:#333;border:0;border-bottom:1px solid #e5e5e5}label{display:inline-block;max-width:100%;margin-bottom:5px;font-weight:700}input[type=search]{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:none;-moz-appearance:none;appearance:none}input[type=checkbox],input[type=radio]{margin:4px 0 0;margin-top:1px\9;line-height:normal}fieldset[disabled] input[type=checkbox],fieldset[disabled] input[type=radio],input[type=checkbox].disabled,input[type=checkbox][disabled],input[type=radio].disabled,input[type=radio][disabled]{cursor:not-allowed}input[type=file]{display:block}input[type=range]{display:block;width:100%}select[multiple],select[size]{height:auto}input[type=checkbox]:focus,input[type=file]:focus,input[type=radio]:focus{outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}output{display:block;padding-top:7px;font-size:14px;line-height:1.42857143;color:#555}.form-control{display:block;width:100%;height:34px;padding:6px 12px;font-size:14px;line-height:1.42857143;color:#555;background-color:#fff;background-image:none;border:1px solid #ccc;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075);-webkit-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;-o-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;-webkit-transition:border-color ease-in-out .15s,-webkit-box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,-webkit-box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s,-webkit-box-shadow ease-in-out .15s}.form-control:focus{border-color:#66afe9;outline:0;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6)}.form-control::-moz-placeholder{color:#999;opacity:1}.form-control:-ms-input-placeholder{color:#999}.form-control::-webkit-input-placeholder{color:#999}.form-control::-ms-expand{background-color:transparent;border:0}.form-control[disabled],.form-control[readonly],fieldset[disabled] .form-control{background-color:#eee;opacity:1}.form-control[disabled],fieldset[disabled] .form-control{cursor:not-allowed}textarea.form-control{height:auto}@media screen and (-webkit-min-device-pixel-ratio:0){input[type=date].form-control,input[type=datetime-local].form-control,input[type=month].form-control,input[type=time].form-control{line-height:34px}.input-group-sm input[type=date],.input-group-sm input[type=datetime-local],.input-group-sm input[type=month],.input-group-sm input[type=time],input[type=date].input-sm,input[type=datetime-local].input-sm,input[type=month].input-sm,input[type=time].input-sm{line-height:30px}.input-group-lg input[type=date],.input-group-lg input[type=datetime-local],.input-group-lg input[type=month],.input-group-lg input[type=time],input[type=date].input-lg,input[type=datetime-local].input-lg,input[type=month].input-lg,input[type=time].input-lg{line-height:46px}}.form-group{margin-bottom:15px}.checkbox,.radio{position:relative;display:block;margin-top:10px;margin-bottom:10px}.checkbox.disabled label,.radio.disabled label,fieldset[disabled] .checkbox label,fieldset[disabled] .radio label{cursor:not-allowed}.checkbox label,.radio label{min-height:20px;padding-left:20px;margin-bottom:0;font-weight:400;cursor:pointer}.checkbox input[type=checkbox],.checkbox-inline input[type=checkbox],.radio input[type=radio],.radio-inline input[type=radio]{position:absolute;margin-top:4px\9;margin-left:-20px}.checkbox+.checkbox,.radio+.radio{margin-top:-5px}.checkbox-inline,.radio-inline{position:relative;display:inline-block;padding-left:20px;margin-bottom:0;font-weight:400;vertical-align:middle;cursor:pointer}.checkbox-inline.disabled,.radio-inline.disabled,fieldset[disabled] .checkbox-inline,fieldset[disabled] .radio-inline{cursor:not-allowed}.checkbox-inline+.checkbox-inline,.radio-inline+.radio-inline{margin-top:0;margin-left:10px}.form-control-static{min-height:34px;padding-top:7px;padding-bottom:7px;margin-bottom:0}.form-control-static.input-lg,.form-control-static.input-sm{padding-right:0;padding-left:0}.input-sm{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-sm{height:30px;line-height:30px}select[multiple].input-sm,textarea.input-sm{height:auto}.form-group-sm .form-control{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.form-group-sm select.form-control{height:30px;line-height:30px}.form-group-sm select[multiple].form-control,.form-group-sm textarea.form-control{height:auto}.form-group-sm .form-control-static{height:30px;min-height:32px;padding:6px 10px;font-size:12px;line-height:1.5}.input-lg{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:6px}select.input-lg{height:46px;line-height:46px}select[multiple].input-lg,textarea.input-lg{height:auto}.form-group-lg .form-control{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:6px}.form-group-lg select.form-control{height:46px;line-height:46px}.form-group-lg select[multiple].form-control,.form-group-lg textarea.form-control{height:auto}.form-group-lg .form-control-static{height:46px;min-height:38px;padding:11px 16px;font-size:18px;line-height:1.3333333}.has-feedback{position:relative}.has-feedback .form-control{padding-right:42.5px}.form-control-feedback{position:absolute;top:0;right:0;z-index:2;display:block;width:34px;height:34px;line-height:34px;text-align:center;pointer-events:none}.form-group-lg .form-control+.form-control-feedback,.input-group-lg+.form-control-feedback,.input-lg+.form-control-feedback{width:46px;height:46px;line-height:46px}.form-group-sm .form-control+.form-control-feedback,.input-group-sm+.form-control-feedback,.input-sm+.form-control-feedback{width:30px;height:30px;line-height:30px}.has-success .checkbox,.has-success .checkbox-inline,.has-success .control-label,.has-success .help-block,.has-success .radio,.has-success .radio-inline,.has-success.checkbox label,.has-success.checkbox-inline label,.has-success.radio label,.has-success.radio-inline label{color:#3c763d}.has-success .form-control{border-color:#3c763d;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-success .form-control:focus{border-color:#2b542c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168}.has-success .input-group-addon{color:#3c763d;background-color:#dff0d8;border-color:#3c763d}.has-success .form-control-feedback{color:#3c763d}.has-warning .checkbox,.has-warning .checkbox-inline,.has-warning .control-label,.has-warning .help-block,.has-warning .radio,.has-warning .radio-inline,.has-warning.checkbox label,.has-warning.checkbox-inline label,.has-warning.radio label,.has-warning.radio-inline label{color:#8a6d3b}.has-warning .form-control{border-color:#8a6d3b;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-warning .form-control:focus{border-color:#66512c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b}.has-warning .input-group-addon{color:#8a6d3b;background-color:#fcf8e3;border-color:#8a6d3b}.has-warning .form-control-feedback{color:#8a6d3b}.has-error .checkbox,.has-error .checkbox-inline,.has-error .control-label,.has-error .help-block,.has-error .radio,.has-error .radio-inline,.has-error.checkbox label,.has-error.checkbox-inline label,.has-error.radio label,.has-error.radio-inline label{color:#a94442}.has-error .form-control{border-color:#a94442;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-error .form-control:focus{border-color:#843534;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483}.has-error .input-group-addon{color:#a94442;background-color:#f2dede;border-color:#a94442}.has-error .form-control-feedback{color:#a94442}.has-feedback label~.form-control-feedback{top:25px}.has-feedback label.sr-only~.form-control-feedback{top:0}.help-block{display:block;margin-top:5px;margin-bottom:10px;color:#737373}@media (min-width:768px){.form-inline .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.form-inline .form-control{display:inline-block;width:auto;vertical-align:middle}.form-inline .form-control-static{display:inline-block}.form-inline .input-group{display:inline-table;vertical-align:middle}.form-inline .input-group .form-control,.form-inline .input-group .input-group-addon,.form-inline .input-group .input-group-btn{width:auto}.form-inline .input-group>.form-control{width:100%}.form-inline .control-label{margin-bottom:0;vertical-align:middle}.form-inline .checkbox,.form-inline .radio{display:inline-block;margin-top:0;margin-bottom:0;vertical-align:middle}.form-inline .checkbox label,.form-inline .radio label{padding-left:0}.form-inline .checkbox input[type=checkbox],.form-inline .radio input[type=radio]{position:relative;margin-left:0}.form-inline .has-feedback .form-control-feedback{top:0}}.form-horizontal .checkbox,.form-horizontal .checkbox-inline,.form-horizontal .radio,.form-horizontal .radio-inline{padding-top:7px;margin-top:0;margin-bottom:0}.form-horizontal .checkbox,.form-horizontal .radio{min-height:27px}.form-horizontal .form-group{margin-right:-15px;margin-left:-15px}@media (min-width:768px){.form-horizontal .control-label{padding-top:7px;margin-bottom:0;text-align:right}}.form-horizontal .has-feedback .form-control-feedback{right:15px}@media (min-width:768px){.form-horizontal .form-group-lg .control-label{padding-top:11px;font-size:18px}}@media (min-width:768px){.form-horizontal .form-group-sm .control-label{padding-top:6px;font-size:12px}}.btn{display:inline-block;margin-bottom:0;font-weight:400;text-align:center;white-space:nowrap;vertical-align:middle;-ms-touch-action:manipulation;touch-action:manipulation;cursor:pointer;background-image:none;border:1px solid transparent;padding:6px 12px;font-size:14px;line-height:1.42857143;border-radius:4px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.btn.active.focus,.btn.active:focus,.btn.focus,.btn:active.focus,.btn:active:focus,.btn:focus{outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}.btn.focus,.btn:focus,.btn:hover{color:#333;text-decoration:none}.btn.active,.btn:active{background-image:none;outline:0;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn.disabled,.btn[disabled],fieldset[disabled] .btn{cursor:not-allowed;filter:alpha(opacity=65);opacity:.65;-webkit-box-shadow:none;box-shadow:none}a.btn.disabled,fieldset[disabled] a.btn{pointer-events:none}.btn-default{color:#333;background-color:#fff;border-color:#ccc}.btn-default.focus,.btn-default:focus{color:#333;background-color:#e6e6e6;border-color:#8c8c8c}.btn-default:hover{color:#333;background-color:#e6e6e6;border-color:#adadad}.btn-default.active,.btn-default:active,.open>.dropdown-toggle.btn-default{color:#333;background-color:#e6e6e6;background-image:none;border-color:#adadad}.btn-default.active.focus,.btn-default.active:focus,.btn-default.active:hover,.btn-default:active.focus,.btn-default:active:focus,.btn-default:active:hover,.open>.dropdown-toggle.btn-default.focus,.open>.dropdown-toggle.btn-default:focus,.open>.dropdown-toggle.btn-default:hover{color:#333;background-color:#d4d4d4;border-color:#8c8c8c}.btn-default.disabled.focus,.btn-default.disabled:focus,.btn-default.disabled:hover,.btn-default[disabled].focus,.btn-default[disabled]:focus,.btn-default[disabled]:hover,fieldset[disabled] .btn-default.focus,fieldset[disabled] .btn-default:focus,fieldset[disabled] .btn-default:hover{background-color:#fff;border-color:#ccc}.btn-default .badge{color:#fff;background-color:#333}.btn-primary{color:#fff;background-color:#337ab7;border-color:#2e6da4}.btn-primary.focus,.btn-primary:focus{color:#fff;background-color:#286090;border-color:#122b40}.btn-primary:hover{color:#fff;background-color:#286090;border-color:#204d74}.btn-primary.active,.btn-primary:active,.open>.dropdown-toggle.btn-primary{color:#fff;background-color:#286090;background-image:none;border-color:#204d74}.btn-primary.active.focus,.btn-primary.active:focus,.btn-primary.active:hover,.btn-primary:active.focus,.btn-primary:active:focus,.btn-primary:active:hover,.open>.dropdown-toggle.btn-primary.focus,.open>.dropdown-toggle.btn-primary:focus,.open>.dropdown-toggle.btn-primary:hover{color:#fff;background-color:#204d74;border-color:#122b40}.btn-primary.disabled.focus,.btn-primary.disabled:focus,.btn-primary.disabled:hover,.btn-primary[disabled].focus,.btn-primary[disabled]:focus,.btn-primary[disabled]:hover,fieldset[disabled] .btn-primary.focus,fieldset[disabled] .btn-primary:focus,fieldset[disabled] .btn-primary:hover{background-color:#337ab7;border-color:#2e6da4}.btn-primary .badge{color:#337ab7;background-color:#fff}.btn-success{color:#fff;background-color:#5cb85c;border-color:#4cae4c}.btn-success.focus,.btn-success:focus{color:#fff;background-color:#449d44;border-color:#255625}.btn-success:hover{color:#fff;background-color:#449d44;border-color:#398439}.btn-success.active,.btn-success:active,.open>.dropdown-toggle.btn-success{color:#fff;background-color:#449d44;background-image:none;border-color:#398439}.btn-success.active.focus,.btn-success.active:focus,.btn-success.active:hover,.btn-success:active.focus,.btn-success:active:focus,.btn-success:active:hover,.open>.dropdown-toggle.btn-success.focus,.open>.dropdown-toggle.btn-success:focus,.open>.dropdown-toggle.btn-success:hover{color:#fff;background-color:#398439;border-color:#255625}.btn-success.disabled.focus,.btn-success.disabled:focus,.btn-success.disabled:hover,.btn-success[disabled].focus,.btn-success[disabled]:focus,.btn-success[disabled]:hover,fieldset[disabled] .btn-success.focus,fieldset[disabled] .btn-success:focus,fieldset[disabled] .btn-success:hover{background-color:#5cb85c;border-color:#4cae4c}.btn-success .badge{color:#5cb85c;background-color:#fff}.btn-info{color:#fff;background-color:#5bc0de;border-color:#46b8da}.btn-info.focus,.btn-info:focus{color:#fff;background-color:#31b0d5;border-color:#1b6d85}.btn-info:hover{color:#fff;background-color:#31b0d5;border-color:#269abc}.btn-info.active,.btn-info:active,.open>.dropdown-toggle.btn-info{color:#fff;background-color:#31b0d5;background-image:none;border-color:#269abc}.btn-info.active.focus,.btn-info.active:focus,.btn-info.active:hover,.btn-info:active.focus,.btn-info:active:focus,.btn-info:active:hover,.open>.dropdown-toggle.btn-info.focus,.open>.dropdown-toggle.btn-info:focus,.open>.dropdown-toggle.btn-info:hover{color:#fff;background-color:#269abc;border-color:#1b6d85}.btn-info.disabled.focus,.btn-info.disabled:focus,.btn-info.disabled:hover,.btn-info[disabled].focus,.btn-info[disabled]:focus,.btn-info[disabled]:hover,fieldset[disabled] .btn-info.focus,fieldset[disabled] .btn-info:focus,fieldset[disabled] .btn-info:hover{background-color:#5bc0de;border-color:#46b8da}.btn-info .badge{color:#5bc0de;background-color:#fff}.btn-warning{color:#fff;background-color:#f0ad4e;border-color:#eea236}.btn-warning.focus,.btn-warning:focus{color:#fff;background-color:#ec971f;border-color:#985f0d}.btn-warning:hover{color:#fff;background-color:#ec971f;border-color:#d58512}.btn-warning.active,.btn-warning:active,.open>.dropdown-toggle.btn-warning{color:#fff;background-color:#ec971f;background-image:none;border-color:#d58512}.btn-warning.active.focus,.btn-warning.active:focus,.btn-warning.active:hover,.btn-warning:active.focus,.btn-warning:active:focus,.btn-warning:active:hover,.open>.dropdown-toggle.btn-warning.focus,.open>.dropdown-toggle.btn-warning:focus,.open>.dropdown-toggle.btn-warning:hover{color:#fff;background-color:#d58512;border-color:#985f0d}.btn-warning.disabled.focus,.btn-warning.disabled:focus,.btn-warning.disabled:hover,.btn-warning[disabled].focus,.btn-warning[disabled]:focus,.btn-warning[disabled]:hover,fieldset[disabled] .btn-warning.focus,fieldset[disabled] .btn-warning:focus,fieldset[disabled] .btn-warning:hover{background-color:#f0ad4e;border-color:#eea236}.btn-warning .badge{color:#f0ad4e;background-color:#fff}.btn-danger{color:#fff;background-color:#d9534f;border-color:#d43f3a}.btn-danger.focus,.btn-danger:focus{color:#fff;background-color:#c9302c;border-color:#761c19}.btn-danger:hover{color:#fff;background-color:#c9302c;border-color:#ac2925}.btn-danger.active,.btn-danger:active,.open>.dropdown-toggle.btn-danger{color:#fff;background-color:#c9302c;background-image:none;border-color:#ac2925}.btn-danger.active.focus,.btn-danger.active:focus,.btn-danger.active:hover,.btn-danger:active.focus,.btn-danger:active:focus,.btn-danger:active:hover,.open>.dropdown-toggle.btn-danger.focus,.open>.dropdown-toggle.btn-danger:focus,.open>.dropdown-toggle.btn-danger:hover{color:#fff;background-color:#ac2925;border-color:#761c19}.btn-danger.disabled.focus,.btn-danger.disabled:focus,.btn-danger.disabled:hover,.btn-danger[disabled].focus,.btn-danger[disabled]:focus,.btn-danger[disabled]:hover,fieldset[disabled] .btn-danger.focus,fieldset[disabled] .btn-danger:focus,fieldset[disabled] .btn-danger:hover{background-color:#d9534f;border-color:#d43f3a}.btn-danger .badge{color:#d9534f;background-color:#fff}.btn-link{font-weight:400;color:#337ab7;border-radius:0}.btn-link,.btn-link.active,.btn-link:active,.btn-link[disabled],fieldset[disabled] .btn-link{background-color:transparent;-webkit-box-shadow:none;box-shadow:none}.btn-link,.btn-link:active,.btn-link:focus,.btn-link:hover{border-color:transparent}.btn-link:focus,.btn-link:hover{color:#23527c;text-decoration:underline;background-color:transparent}.btn-link[disabled]:focus,.btn-link[disabled]:hover,fieldset[disabled] .btn-link:focus,fieldset[disabled] .btn-link:hover{color:#777;text-decoration:none}.btn-group-lg>.btn,.btn-lg{padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:6px}.btn-group-sm>.btn,.btn-sm{padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.btn-group-xs>.btn,.btn-xs{padding:1px 5px;font-size:12px;line-height:1.5;border-radius:3px}.btn-block{display:block;width:100%}.btn-block+.btn-block{margin-top:5px}input[type=button].btn-block,input[type=reset].btn-block,input[type=submit].btn-block{width:100%}.fade{opacity:0;-webkit-transition:opacity .15s linear;-o-transition:opacity .15s linear;transition:opacity .15s linear}.fade.in{opacity:1}.collapse{display:none}.collapse.in{display:block}tr.collapse.in{display:table-row}tbody.collapse.in{display:table-row-group}.collapsing{position:relative;height:0;overflow:hidden;-webkit-transition-property:height,visibility;-o-transition-property:height,visibility;transition-property:height,visibility;-webkit-transition-duration:.35s;-o-transition-duration:.35s;transition-duration:.35s;-webkit-transition-timing-function:ease;-o-transition-timing-function:ease;transition-timing-function:ease}.caret{display:inline-block;width:0;height:0;margin-left:2px;vertical-align:middle;border-top:4px dashed;border-top:4px solid\9;border-right:4px solid transparent;border-left:4px solid transparent}.dropdown,.dropup{position:relative}.dropdown-toggle:focus{outline:0}.dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;display:none;float:left;min-width:160px;padding:5px 0;margin:2px 0 0;font-size:14px;text-align:left;list-style:none;background-color:#fff;background-clip:padding-box;border:1px solid #ccc;border:1px solid rgba(0,0,0,.15);border-radius:4px;-webkit-box-shadow:0 6px 12px rgba(0,0,0,.175);box-shadow:0 6px 12px rgba(0,0,0,.175)}.dropdown-menu.pull-right{right:0;left:auto}.dropdown-menu .divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.dropdown-menu>li>a{display:block;padding:3px 20px;clear:both;font-weight:400;line-height:1.42857143;color:#333;white-space:nowrap}.dropdown-menu>li>a:focus,.dropdown-menu>li>a:hover{color:#262626;text-decoration:none;background-color:#f5f5f5}.dropdown-menu>.active>a,.dropdown-menu>.active>a:focus,.dropdown-menu>.active>a:hover{color:#fff;text-decoration:none;background-color:#337ab7;outline:0}.dropdown-menu>.disabled>a,.dropdown-menu>.disabled>a:focus,.dropdown-menu>.disabled>a:hover{color:#777}.dropdown-menu>.disabled>a:focus,.dropdown-menu>.disabled>a:hover{text-decoration:none;cursor:not-allowed;background-color:transparent;background-image:none;filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.open>.dropdown-menu{display:block}.open>a{outline:0}.dropdown-menu-right{right:0;left:auto}.dropdown-menu-left{right:auto;left:0}.dropdown-header{display:block;padding:3px 20px;font-size:12px;line-height:1.42857143;color:#777;white-space:nowrap}.dropdown-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:990}.pull-right>.dropdown-menu{right:0;left:auto}.dropup .caret,.navbar-fixed-bottom .dropdown .caret{content:"";border-top:0;border-bottom:4px dashed;border-bottom:4px solid\9}.dropup .dropdown-menu,.navbar-fixed-bottom .dropdown .dropdown-menu{top:auto;bottom:100%;margin-bottom:2px}@media (min-width:768px){.navbar-right .dropdown-menu{right:0;left:auto}.navbar-right .dropdown-menu-left{right:auto;left:0}}.btn-group,.btn-group-vertical{position:relative;display:inline-block;vertical-align:middle}.btn-group-vertical>.btn,.btn-group>.btn{position:relative;float:left}.btn-group-vertical>.btn.active,.btn-group-vertical>.btn:active,.btn-group-vertical>.btn:focus,.btn-group-vertical>.btn:hover,.btn-group>.btn.active,.btn-group>.btn:active,.btn-group>.btn:focus,.btn-group>.btn:hover{z-index:2}.btn-group .btn+.btn,.btn-group .btn+.btn-group,.btn-group .btn-group+.btn,.btn-group .btn-group+.btn-group{margin-left:-1px}.btn-toolbar{margin-left:-5px}.btn-toolbar .btn,.btn-toolbar .btn-group,.btn-toolbar .input-group{float:left}.btn-toolbar>.btn,.btn-toolbar>.btn-group,.btn-toolbar>.input-group{margin-left:5px}.btn-group>.btn:not(:first-child):not(:last-child):not(.dropdown-toggle){border-radius:0}.btn-group>.btn:first-child{margin-left:0}.btn-group>.btn:first-child:not(:last-child):not(.dropdown-toggle){border-top-right-radius:0;border-bottom-right-radius:0}.btn-group>.btn:last-child:not(:first-child),.btn-group>.dropdown-toggle:not(:first-child){border-top-left-radius:0;border-bottom-left-radius:0}.btn-group>.btn-group{float:left}.btn-group>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.btn-group>.btn-group:first-child:not(:last-child)>.btn:last-child,.btn-group>.btn-group:first-child:not(:last-child)>.dropdown-toggle{border-top-right-radius:0;border-bottom-right-radius:0}.btn-group>.btn-group:last-child:not(:first-child)>.btn:first-child{border-top-left-radius:0;border-bottom-left-radius:0}.btn-group .dropdown-toggle:active,.btn-group.open .dropdown-toggle{outline:0}.btn-group>.btn+.dropdown-toggle{padding-right:8px;padding-left:8px}.btn-group>.btn-lg+.dropdown-toggle{padding-right:12px;padding-left:12px}.btn-group.open .dropdown-toggle{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn-group.open .dropdown-toggle.btn-link{-webkit-box-shadow:none;box-shadow:none}.btn .caret{margin-left:0}.btn-lg .caret{border-width:5px 5px 0;border-bottom-width:0}.dropup .btn-lg .caret{border-width:0 5px 5px}.btn-group-vertical>.btn,.btn-group-vertical>.btn-group,.btn-group-vertical>.btn-group>.btn{display:block;float:none;width:100%;max-width:100%}.btn-group-vertical>.btn-group>.btn{float:none}.btn-group-vertical>.btn+.btn,.btn-group-vertical>.btn+.btn-group,.btn-group-vertical>.btn-group+.btn,.btn-group-vertical>.btn-group+.btn-group{margin-top:-1px;margin-left:0}.btn-group-vertical>.btn:not(:first-child):not(:last-child){border-radius:0}.btn-group-vertical>.btn:first-child:not(:last-child){border-top-left-radius:4px;border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn:last-child:not(:first-child){border-top-left-radius:0;border-top-right-radius:0;border-bottom-right-radius:4px;border-bottom-left-radius:4px}.btn-group-vertical>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.btn-group-vertical>.btn-group:first-child:not(:last-child)>.btn:last-child,.btn-group-vertical>.btn-group:first-child:not(:last-child)>.dropdown-toggle{border-bottom-right-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn-group:last-child:not(:first-child)>.btn:first-child{border-top-left-radius:0;border-top-right-radius:0}.btn-group-justified{display:table;width:100%;table-layout:fixed;border-collapse:separate}.btn-group-justified>.btn,.btn-group-justified>.btn-group{display:table-cell;float:none;width:1%}.btn-group-justified>.btn-group .btn{width:100%}.btn-group-justified>.btn-group .dropdown-menu{left:auto}[data-toggle=buttons]>.btn input[type=checkbox],[data-toggle=buttons]>.btn input[type=radio],[data-toggle=buttons]>.btn-group>.btn input[type=checkbox],[data-toggle=buttons]>.btn-group>.btn input[type=radio]{position:absolute;clip:rect(0,0,0,0);pointer-events:none}.input-group{position:relative;display:table;border-collapse:separate}.input-group[class*=col-]{float:none;padding-right:0;padding-left:0}.input-group .form-control{position:relative;z-index:2;float:left;width:100%;margin-bottom:0}.input-group .form-control:focus{z-index:3}.input-group-lg>.form-control,.input-group-lg>.input-group-addon,.input-group-lg>.input-group-btn>.btn{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:6px}select.input-group-lg>.form-control,select.input-group-lg>.input-group-addon,select.input-group-lg>.input-group-btn>.btn{height:46px;line-height:46px}select[multiple].input-group-lg>.form-control,select[multiple].input-group-lg>.input-group-addon,select[multiple].input-group-lg>.input-group-btn>.btn,textarea.input-group-lg>.form-control,textarea.input-group-lg>.input-group-addon,textarea.input-group-lg>.input-group-btn>.btn{height:auto}.input-group-sm>.form-control,.input-group-sm>.input-group-addon,.input-group-sm>.input-group-btn>.btn{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-group-sm>.form-control,select.input-group-sm>.input-group-addon,select.input-group-sm>.input-group-btn>.btn{height:30px;line-height:30px}select[multiple].input-group-sm>.form-control,select[multiple].input-group-sm>.input-group-addon,select[multiple].input-group-sm>.input-group-btn>.btn,textarea.input-group-sm>.form-control,textarea.input-group-sm>.input-group-addon,textarea.input-group-sm>.input-group-btn>.btn{height:auto}.input-group .form-control,.input-group-addon,.input-group-btn{display:table-cell}.input-group .form-control:not(:first-child):not(:last-child),.input-group-addon:not(:first-child):not(:last-child),.input-group-btn:not(:first-child):not(:last-child){border-radius:0}.input-group-addon,.input-group-btn{width:1%;white-space:nowrap;vertical-align:middle}.input-group-addon{padding:6px 12px;font-size:14px;font-weight:400;line-height:1;color:#555;text-align:center;background-color:#eee;border:1px solid #ccc;border-radius:4px}.input-group-addon.input-sm{padding:5px 10px;font-size:12px;border-radius:3px}.input-group-addon.input-lg{padding:10px 16px;font-size:18px;border-radius:6px}.input-group-addon input[type=checkbox],.input-group-addon input[type=radio]{margin-top:0}.input-group .form-control:first-child,.input-group-addon:first-child,.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group>.btn,.input-group-btn:first-child>.dropdown-toggle,.input-group-btn:last-child>.btn-group:not(:last-child)>.btn,.input-group-btn:last-child>.btn:not(:last-child):not(.dropdown-toggle){border-top-right-radius:0;border-bottom-right-radius:0}.input-group-addon:first-child{border-right:0}.input-group .form-control:last-child,.input-group-addon:last-child,.input-group-btn:first-child>.btn-group:not(:first-child)>.btn,.input-group-btn:first-child>.btn:not(:first-child),.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group>.btn,.input-group-btn:last-child>.dropdown-toggle{border-top-left-radius:0;border-bottom-left-radius:0}.input-group-addon:last-child{border-left:0}.input-group-btn{position:relative;font-size:0;white-space:nowrap}.input-group-btn>.btn{position:relative}.input-group-btn>.btn+.btn{margin-left:-1px}.input-group-btn>.btn:active,.input-group-btn>.btn:focus,.input-group-btn>.btn:hover{z-index:2}.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group{margin-right:-1px}.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group{z-index:2;margin-left:-1px}.nav{padding-left:0;margin-bottom:0;list-style:none}.nav>li{position:relative;display:block}.nav>li>a{position:relative;display:block;padding:10px 15px}.nav>li>a:focus,.nav>li>a:hover{text-decoration:none;background-color:#eee}.nav>li.disabled>a{color:#777}.nav>li.disabled>a:focus,.nav>li.disabled>a:hover{color:#777;text-decoration:none;cursor:not-allowed;background-color:transparent}.nav .open>a,.nav .open>a:focus,.nav .open>a:hover{background-color:#eee;border-color:#337ab7}.nav .nav-divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.nav>li>a>img{max-width:none}.nav-tabs{border-bottom:1px solid #ddd}.nav-tabs>li{float:left;margin-bottom:-1px}.nav-tabs>li>a{margin-right:2px;line-height:1.42857143;border:1px solid transparent;border-radius:4px 4px 0 0}.nav-tabs>li>a:hover{border-color:#eee #eee #ddd}.nav-tabs>li.active>a,.nav-tabs>li.active>a:focus,.nav-tabs>li.active>a:hover{color:#555;cursor:default;background-color:#fff;border:1px solid #ddd;border-bottom-color:transparent}.nav-tabs.nav-justified{width:100%;border-bottom:0}.nav-tabs.nav-justified>li{float:none}.nav-tabs.nav-justified>li>a{margin-bottom:5px;text-align:center}.nav-tabs.nav-justified>.dropdown .dropdown-menu{top:auto;left:auto}@media (min-width:768px){.nav-tabs.nav-justified>li{display:table-cell;width:1%}.nav-tabs.nav-justified>li>a{margin-bottom:0}}.nav-tabs.nav-justified>li>a{margin-right:0;border-radius:4px}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:focus,.nav-tabs.nav-justified>.active>a:hover{border:1px solid #ddd}@media (min-width:768px){.nav-tabs.nav-justified>li>a{border-bottom:1px solid #ddd;border-radius:4px 4px 0 0}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:focus,.nav-tabs.nav-justified>.active>a:hover{border-bottom-color:#fff}}.nav-pills>li{float:left}.nav-pills>li>a{border-radius:4px}.nav-pills>li+li{margin-left:2px}.nav-pills>li.active>a,.nav-pills>li.active>a:focus,.nav-pills>li.active>a:hover{color:#fff;background-color:#337ab7}.nav-stacked>li{float:none}.nav-stacked>li+li{margin-top:2px;margin-left:0}.nav-justified{width:100%}.nav-justified>li{float:none}.nav-justified>li>a{margin-bottom:5px;text-align:center}.nav-justified>.dropdown .dropdown-menu{top:auto;left:auto}@media (min-width:768px){.nav-justified>li{display:table-cell;width:1%}.nav-justified>li>a{margin-bottom:0}}.nav-tabs-justified{border-bottom:0}.nav-tabs-justified>li>a{margin-right:0;border-radius:4px}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:focus,.nav-tabs-justified>.active>a:hover{border:1px solid #ddd}@media (min-width:768px){.nav-tabs-justified>li>a{border-bottom:1px solid #ddd;border-radius:4px 4px 0 0}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:focus,.nav-tabs-justified>.active>a:hover{border-bottom-color:#fff}}.tab-content>.tab-pane{display:none}.tab-content>.active{display:block}.nav-tabs .dropdown-menu{margin-top:-1px;border-top-left-radius:0;border-top-right-radius:0}.navbar{position:relative;min-height:50px;margin-bottom:20px;border:1px solid transparent}@media (min-width:768px){.navbar{border-radius:4px}}@media (min-width:768px){.navbar-header{float:left}}.navbar-collapse{padding-right:15px;padding-left:15px;overflow-x:visible;border-top:1px solid transparent;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 0 rgba(255,255,255,.1);-webkit-overflow-scrolling:touch}.navbar-collapse.in{overflow-y:auto}@media (min-width:768px){.navbar-collapse{width:auto;border-top:0;-webkit-box-shadow:none;box-shadow:none}.navbar-collapse.collapse{display:block!important;height:auto!important;padding-bottom:0;overflow:visible!important}.navbar-collapse.in{overflow-y:visible}.navbar-fixed-bottom .navbar-collapse,.navbar-fixed-top .navbar-collapse,.navbar-static-top .navbar-collapse{padding-right:0;padding-left:0}}.navbar-fixed-bottom,.navbar-fixed-top{position:fixed;right:0;left:0;z-index:1030}.navbar-fixed-bottom .navbar-collapse,.navbar-fixed-top .navbar-collapse{max-height:340px}@media (max-device-width:480px) and (orientation:landscape){.navbar-fixed-bottom .navbar-collapse,.navbar-fixed-top .navbar-collapse{max-height:200px}}@media (min-width:768px){.navbar-fixed-bottom,.navbar-fixed-top{border-radius:0}}.navbar-fixed-top{top:0;border-width:0 0 1px}.navbar-fixed-bottom{bottom:0;margin-bottom:0;border-width:1px 0 0}.container-fluid>.navbar-collapse,.container-fluid>.navbar-header,.container>.navbar-collapse,.container>.navbar-header{margin-right:-15px;margin-left:-15px}@media (min-width:768px){.container-fluid>.navbar-collapse,.container-fluid>.navbar-header,.container>.navbar-collapse,.container>.navbar-header{margin-right:0;margin-left:0}}.navbar-static-top{z-index:1000;border-width:0 0 1px}@media (min-width:768px){.navbar-static-top{border-radius:0}}.navbar-brand{float:left;height:50px;padding:15px 15px;font-size:18px;line-height:20px}.navbar-brand:focus,.navbar-brand:hover{text-decoration:none}.navbar-brand>img{display:block}@media (min-width:768px){.navbar>.container .navbar-brand,.navbar>.container-fluid .navbar-brand{margin-left:-15px}}.navbar-toggle{position:relative;float:right;padding:9px 10px;margin-right:15px;margin-top:8px;margin-bottom:8px;background-color:transparent;background-image:none;border:1px solid transparent;border-radius:4px}.navbar-toggle:focus{outline:0}.navbar-toggle .icon-bar{display:block;width:22px;height:2px;border-radius:1px}.navbar-toggle .icon-bar+.icon-bar{margin-top:4px}@media (min-width:768px){.navbar-toggle{display:none}}.navbar-nav{margin:7.5px -15px}.navbar-nav>li>a{padding-top:10px;padding-bottom:10px;line-height:20px}@media (max-width:767px){.navbar-nav .open .dropdown-menu{position:static;float:none;width:auto;margin-top:0;background-color:transparent;border:0;-webkit-box-shadow:none;box-shadow:none}.navbar-nav .open .dropdown-menu .dropdown-header,.navbar-nav .open .dropdown-menu>li>a{padding:5px 15px 5px 25px}.navbar-nav .open .dropdown-menu>li>a{line-height:20px}.navbar-nav .open .dropdown-menu>li>a:focus,.navbar-nav .open .dropdown-menu>li>a:hover{background-image:none}}@media (min-width:768px){.navbar-nav{float:left;margin:0}.navbar-nav>li{float:left}.navbar-nav>li>a{padding-top:15px;padding-bottom:15px}}.navbar-form{padding:10px 15px;margin-right:-15px;margin-left:-15px;border-top:1px solid transparent;border-bottom:1px solid transparent;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1);margin-top:8px;margin-bottom:8px}@media (min-width:768px){.navbar-form .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.navbar-form .form-control{display:inline-block;width:auto;vertical-align:middle}.navbar-form .form-control-static{display:inline-block}.navbar-form .input-group{display:inline-table;vertical-align:middle}.navbar-form .input-group .form-control,.navbar-form .input-group .input-group-addon,.navbar-form .input-group .input-group-btn{width:auto}.navbar-form .input-group>.form-control{width:100%}.navbar-form .control-label{margin-bottom:0;vertical-align:middle}.navbar-form .checkbox,.navbar-form .radio{display:inline-block;margin-top:0;margin-bottom:0;vertical-align:middle}.navbar-form .checkbox label,.navbar-form .radio label{padding-left:0}.navbar-form .checkbox input[type=checkbox],.navbar-form .radio input[type=radio]{position:relative;margin-left:0}.navbar-form .has-feedback .form-control-feedback{top:0}}@media (max-width:767px){.navbar-form .form-group{margin-bottom:5px}.navbar-form .form-group:last-child{margin-bottom:0}}@media (min-width:768px){.navbar-form{width:auto;padding-top:0;padding-bottom:0;margin-right:0;margin-left:0;border:0;-webkit-box-shadow:none;box-shadow:none}}.navbar-nav>li>.dropdown-menu{margin-top:0;border-top-left-radius:0;border-top-right-radius:0}.navbar-fixed-bottom .navbar-nav>li>.dropdown-menu{margin-bottom:0;border-top-left-radius:4px;border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.navbar-btn{margin-top:8px;margin-bottom:8px}.navbar-btn.btn-sm{margin-top:10px;margin-bottom:10px}.navbar-btn.btn-xs{margin-top:14px;margin-bottom:14px}.navbar-text{margin-top:15px;margin-bottom:15px}@media (min-width:768px){.navbar-text{float:left;margin-right:15px;margin-left:15px}}@media (min-width:768px){.navbar-left{float:left!important}.navbar-right{float:right!important;margin-right:-15px}.navbar-right~.navbar-right{margin-right:0}}.navbar-default{background-color:#f8f8f8;border-color:#e7e7e7}.navbar-default .navbar-brand{color:#777}.navbar-default .navbar-brand:focus,.navbar-default .navbar-brand:hover{color:#5e5e5e;background-color:transparent}.navbar-default .navbar-text{color:#777}.navbar-default .navbar-nav>li>a{color:#777}.navbar-default .navbar-nav>li>a:focus,.navbar-default .navbar-nav>li>a:hover{color:#333;background-color:transparent}.navbar-default .navbar-nav>.active>a,.navbar-default .navbar-nav>.active>a:focus,.navbar-default .navbar-nav>.active>a:hover{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav>.disabled>a,.navbar-default .navbar-nav>.disabled>a:focus,.navbar-default .navbar-nav>.disabled>a:hover{color:#ccc;background-color:transparent}.navbar-default .navbar-nav>.open>a,.navbar-default .navbar-nav>.open>a:focus,.navbar-default .navbar-nav>.open>a:hover{color:#555;background-color:#e7e7e7}@media (max-width:767px){.navbar-default .navbar-nav .open .dropdown-menu>li>a{color:#777}.navbar-default .navbar-nav .open .dropdown-menu>li>a:focus,.navbar-default .navbar-nav .open .dropdown-menu>li>a:hover{color:#333;background-color:transparent}.navbar-default .navbar-nav .open .dropdown-menu>.active>a,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:focus,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:hover{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:focus,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:hover{color:#ccc;background-color:transparent}}.navbar-default .navbar-toggle{border-color:#ddd}.navbar-default .navbar-toggle:focus,.navbar-default .navbar-toggle:hover{background-color:#ddd}.navbar-default .navbar-toggle .icon-bar{background-color:#888}.navbar-default .navbar-collapse,.navbar-default .navbar-form{border-color:#e7e7e7}.navbar-default .navbar-link{color:#777}.navbar-default .navbar-link:hover{color:#333}.navbar-default .btn-link{color:#777}.navbar-default .btn-link:focus,.navbar-default .btn-link:hover{color:#333}.navbar-default .btn-link[disabled]:focus,.navbar-default .btn-link[disabled]:hover,fieldset[disabled] .navbar-default .btn-link:focus,fieldset[disabled] .navbar-default .btn-link:hover{color:#ccc}.navbar-inverse{background-color:#222;border-color:#080808}.navbar-inverse .navbar-brand{color:#9d9d9d}.navbar-inverse .navbar-brand:focus,.navbar-inverse .navbar-brand:hover{color:#fff;background-color:transparent}.navbar-inverse .navbar-text{color:#9d9d9d}.navbar-inverse .navbar-nav>li>a{color:#9d9d9d}.navbar-inverse .navbar-nav>li>a:focus,.navbar-inverse .navbar-nav>li>a:hover{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav>.active>a,.navbar-inverse .navbar-nav>.active>a:focus,.navbar-inverse .navbar-nav>.active>a:hover{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav>.disabled>a,.navbar-inverse .navbar-nav>.disabled>a:focus,.navbar-inverse .navbar-nav>.disabled>a:hover{color:#444;background-color:transparent}.navbar-inverse .navbar-nav>.open>a,.navbar-inverse .navbar-nav>.open>a:focus,.navbar-inverse .navbar-nav>.open>a:hover{color:#fff;background-color:#080808}@media (max-width:767px){.navbar-inverse .navbar-nav .open .dropdown-menu>.dropdown-header{border-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu .divider{background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a{color:#9d9d9d}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:focus,.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:hover{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:focus,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:hover{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:focus,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:hover{color:#444;background-color:transparent}}.navbar-inverse .navbar-toggle{border-color:#333}.navbar-inverse .navbar-toggle:focus,.navbar-inverse .navbar-toggle:hover{background-color:#333}.navbar-inverse .navbar-toggle .icon-bar{background-color:#fff}.navbar-inverse .navbar-collapse,.navbar-inverse .navbar-form{border-color:#101010}.navbar-inverse .navbar-link{color:#9d9d9d}.navbar-inverse .navbar-link:hover{color:#fff}.navbar-inverse .btn-link{color:#9d9d9d}.navbar-inverse .btn-link:focus,.navbar-inverse .btn-link:hover{color:#fff}.navbar-inverse .btn-link[disabled]:focus,.navbar-inverse .btn-link[disabled]:hover,fieldset[disabled] .navbar-inverse .btn-link:focus,fieldset[disabled] .navbar-inverse .btn-link:hover{color:#444}.breadcrumb{padding:8px 15px;margin-bottom:20px;list-style:none;background-color:#f5f5f5;border-radius:4px}.breadcrumb>li{display:inline-block}.breadcrumb>li+li:before{padding:0 5px;color:#ccc;content:"/\00a0"}.breadcrumb>.active{color:#777}.pagination{display:inline-block;padding-left:0;margin:20px 0;border-radius:4px}.pagination>li{display:inline}.pagination>li>a,.pagination>li>span{position:relative;float:left;padding:6px 12px;margin-left:-1px;line-height:1.42857143;color:#337ab7;text-decoration:none;background-color:#fff;border:1px solid #ddd}.pagination>li>a:focus,.pagination>li>a:hover,.pagination>li>span:focus,.pagination>li>span:hover{z-index:2;color:#23527c;background-color:#eee;border-color:#ddd}.pagination>li:first-child>a,.pagination>li:first-child>span{margin-left:0;border-top-left-radius:4px;border-bottom-left-radius:4px}.pagination>li:last-child>a,.pagination>li:last-child>span{border-top-right-radius:4px;border-bottom-right-radius:4px}.pagination>.active>a,.pagination>.active>a:focus,.pagination>.active>a:hover,.pagination>.active>span,.pagination>.active>span:focus,.pagination>.active>span:hover{z-index:3;color:#fff;cursor:default;background-color:#337ab7;border-color:#337ab7}.pagination>.disabled>a,.pagination>.disabled>a:focus,.pagination>.disabled>a:hover,.pagination>.disabled>span,.pagination>.disabled>span:focus,.pagination>.disabled>span:hover{color:#777;cursor:not-allowed;background-color:#fff;border-color:#ddd}.pagination-lg>li>a,.pagination-lg>li>span{padding:10px 16px;font-size:18px;line-height:1.3333333}.pagination-lg>li:first-child>a,.pagination-lg>li:first-child>span{border-top-left-radius:6px;border-bottom-left-radius:6px}.pagination-lg>li:last-child>a,.pagination-lg>li:last-child>span{border-top-right-radius:6px;border-bottom-right-radius:6px}.pagination-sm>li>a,.pagination-sm>li>span{padding:5px 10px;font-size:12px;line-height:1.5}.pagination-sm>li:first-child>a,.pagination-sm>li:first-child>span{border-top-left-radius:3px;border-bottom-left-radius:3px}.pagination-sm>li:last-child>a,.pagination-sm>li:last-child>span{border-top-right-radius:3px;border-bottom-right-radius:3px}.pager{padding-left:0;margin:20px 0;text-align:center;list-style:none}.pager li{display:inline}.pager li>a,.pager li>span{display:inline-block;padding:5px 14px;background-color:#fff;border:1px solid #ddd;border-radius:15px}.pager li>a:focus,.pager li>a:hover{text-decoration:none;background-color:#eee}.pager .next>a,.pager .next>span{float:right}.pager .previous>a,.pager .previous>span{float:left}.pager .disabled>a,.pager .disabled>a:focus,.pager .disabled>a:hover,.pager .disabled>span{color:#777;cursor:not-allowed;background-color:#fff}.label{display:inline;padding:.2em .6em .3em;font-size:75%;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;border-radius:.25em}a.label:focus,a.label:hover{color:#fff;text-decoration:none;cursor:pointer}.label:empty{display:none}.btn .label{position:relative;top:-1px}.label-default{background-color:#777}.label-default[href]:focus,.label-default[href]:hover{background-color:#5e5e5e}.label-primary{background-color:#337ab7}.label-primary[href]:focus,.label-primary[href]:hover{background-color:#286090}.label-success{background-color:#5cb85c}.label-success[href]:focus,.label-success[href]:hover{background-color:#449d44}.label-info{background-color:#5bc0de}.label-info[href]:focus,.label-info[href]:hover{background-color:#31b0d5}.label-warning{background-color:#f0ad4e}.label-warning[href]:focus,.label-warning[href]:hover{background-color:#ec971f}.label-danger{background-color:#d9534f}.label-danger[href]:focus,.label-danger[href]:hover{background-color:#c9302c}.badge{display:inline-block;min-width:10px;padding:3px 7px;font-size:12px;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:middle;background-color:#777;border-radius:10px}.badge:empty{display:none}.btn .badge{position:relative;top:-1px}.btn-group-xs>.btn .badge,.btn-xs .badge{top:0;padding:1px 5px}a.badge:focus,a.badge:hover{color:#fff;text-decoration:none;cursor:pointer}.list-group-item.active>.badge,.nav-pills>.active>a>.badge{color:#337ab7;background-color:#fff}.list-group-item>.badge{float:right}.list-group-item>.badge+.badge{margin-right:5px}.nav-pills>li>a>.badge{margin-left:3px}.jumbotron{padding-top:30px;padding-bottom:30px;margin-bottom:30px;color:inherit;background-color:#eee}.jumbotron .h1,.jumbotron h1{color:inherit}.jumbotron p{margin-bottom:15px;font-size:21px;font-weight:200}.jumbotron>hr{border-top-color:#d5d5d5}.container .jumbotron,.container-fluid .jumbotron{padding-right:15px;padding-left:15px;border-radius:6px}.jumbotron .container{max-width:100%}@media screen and (min-width:768px){.jumbotron{padding-top:48px;padding-bottom:48px}.container .jumbotron,.container-fluid .jumbotron{padding-right:60px;padding-left:60px}.jumbotron .h1,.jumbotron h1{font-size:63px}}.thumbnail{display:block;padding:4px;margin-bottom:20px;line-height:1.42857143;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:border .2s ease-in-out;-o-transition:border .2s ease-in-out;transition:border .2s ease-in-out}.thumbnail a>img,.thumbnail>img{margin-right:auto;margin-left:auto}a.thumbnail.active,a.thumbnail:focus,a.thumbnail:hover{border-color:#337ab7}.thumbnail .caption{padding:9px;color:#333}.alert{padding:15px;margin-bottom:20px;border:1px solid transparent;border-radius:4px}.alert h4{margin-top:0;color:inherit}.alert .alert-link{font-weight:700}.alert>p,.alert>ul{margin-bottom:0}.alert>p+p{margin-top:5px}.alert-dismissable,.alert-dismissible{padding-right:35px}.alert-dismissable .close,.alert-dismissible .close{position:relative;top:-2px;right:-21px;color:inherit}.alert-success{color:#3c763d;background-color:#dff0d8;border-color:#d6e9c6}.alert-success hr{border-top-color:#c9e2b3}.alert-success .alert-link{color:#2b542c}.alert-info{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.alert-info hr{border-top-color:#a6e1ec}.alert-info .alert-link{color:#245269}.alert-warning{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}.alert-warning hr{border-top-color:#f7e1b5}.alert-warning .alert-link{color:#66512c}.alert-danger{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.alert-danger hr{border-top-color:#e4b9c0}.alert-danger .alert-link{color:#843534}@-webkit-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@-o-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}.progress{height:20px;margin-bottom:20px;overflow:hidden;background-color:#f5f5f5;border-radius:4px;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1)}.progress-bar{float:left;width:0%;height:100%;font-size:12px;line-height:20px;color:#fff;text-align:center;background-color:#337ab7;-webkit-box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);-webkit-transition:width .6s ease;-o-transition:width .6s ease;transition:width .6s ease}.progress-bar-striped,.progress-striped .progress-bar{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);-webkit-background-size:40px 40px;background-size:40px 40px}.progress-bar.active,.progress.active .progress-bar{-webkit-animation:progress-bar-stripes 2s linear infinite;-o-animation:progress-bar-stripes 2s linear infinite;animation:progress-bar-stripes 2s linear infinite}.progress-bar-success{background-color:#5cb85c}.progress-striped .progress-bar-success{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-info{background-color:#5bc0de}.progress-striped .progress-bar-info{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-warning{background-color:#f0ad4e}.progress-striped .progress-bar-warning{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-danger{background-color:#d9534f}.progress-striped .progress-bar-danger{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.media{margin-top:15px}.media:first-child{margin-top:0}.media,.media-body{overflow:hidden;zoom:1}.media-body{width:10000px}.media-object{display:block}.media-object.img-thumbnail{max-width:none}.media-right,.media>.pull-right{padding-left:10px}.media-left,.media>.pull-left{padding-right:10px}.media-body,.media-left,.media-right{display:table-cell;vertical-align:top}.media-middle{vertical-align:middle}.media-bottom{vertical-align:bottom}.media-heading{margin-top:0;margin-bottom:5px}.media-list{padding-left:0;list-style:none}.list-group{padding-left:0;margin-bottom:20px}.list-group-item{position:relative;display:block;padding:10px 15px;margin-bottom:-1px;background-color:#fff;border:1px solid #ddd}.list-group-item:first-child{border-top-left-radius:4px;border-top-right-radius:4px}.list-group-item:last-child{margin-bottom:0;border-bottom-right-radius:4px;border-bottom-left-radius:4px}.list-group-item.disabled,.list-group-item.disabled:focus,.list-group-item.disabled:hover{color:#777;cursor:not-allowed;background-color:#eee}.list-group-item.disabled .list-group-item-heading,.list-group-item.disabled:focus .list-group-item-heading,.list-group-item.disabled:hover .list-group-item-heading{color:inherit}.list-group-item.disabled .list-group-item-text,.list-group-item.disabled:focus .list-group-item-text,.list-group-item.disabled:hover .list-group-item-text{color:#777}.list-group-item.active,.list-group-item.active:focus,.list-group-item.active:hover{z-index:2;color:#fff;background-color:#337ab7;border-color:#337ab7}.list-group-item.active .list-group-item-heading,.list-group-item.active .list-group-item-heading>.small,.list-group-item.active .list-group-item-heading>small,.list-group-item.active:focus .list-group-item-heading,.list-group-item.active:focus .list-group-item-heading>.small,.list-group-item.active:focus .list-group-item-heading>small,.list-group-item.active:hover .list-group-item-heading,.list-group-item.active:hover .list-group-item-heading>.small,.list-group-item.active:hover .list-group-item-heading>small{color:inherit}.list-group-item.active .list-group-item-text,.list-group-item.active:focus .list-group-item-text,.list-group-item.active:hover .list-group-item-text{color:#c7ddef}a.list-group-item,button.list-group-item{color:#555}a.list-group-item .list-group-item-heading,button.list-group-item .list-group-item-heading{color:#333}a.list-group-item:focus,a.list-group-item:hover,button.list-group-item:focus,button.list-group-item:hover{color:#555;text-decoration:none;background-color:#f5f5f5}button.list-group-item{width:100%;text-align:left}.list-group-item-success{color:#3c763d;background-color:#dff0d8}a.list-group-item-success,button.list-group-item-success{color:#3c763d}a.list-group-item-success .list-group-item-heading,button.list-group-item-success .list-group-item-heading{color:inherit}a.list-group-item-success:focus,a.list-group-item-success:hover,button.list-group-item-success:focus,button.list-group-item-success:hover{color:#3c763d;background-color:#d0e9c6}a.list-group-item-success.active,a.list-group-item-success.active:focus,a.list-group-item-success.active:hover,button.list-group-item-success.active,button.list-group-item-success.active:focus,button.list-group-item-success.active:hover{color:#fff;background-color:#3c763d;border-color:#3c763d}.list-group-item-info{color:#31708f;background-color:#d9edf7}a.list-group-item-info,button.list-group-item-info{color:#31708f}a.list-group-item-info .list-group-item-heading,button.list-group-item-info .list-group-item-heading{color:inherit}a.list-group-item-info:focus,a.list-group-item-info:hover,button.list-group-item-info:focus,button.list-group-item-info:hover{color:#31708f;background-color:#c4e3f3}a.list-group-item-info.active,a.list-group-item-info.active:focus,a.list-group-item-info.active:hover,button.list-group-item-info.active,button.list-group-item-info.active:focus,button.list-group-item-info.active:hover{color:#fff;background-color:#31708f;border-color:#31708f}.list-group-item-warning{color:#8a6d3b;background-color:#fcf8e3}a.list-group-item-warning,button.list-group-item-warning{color:#8a6d3b}a.list-group-item-warning .list-group-item-heading,button.list-group-item-warning .list-group-item-heading{color:inherit}a.list-group-item-warning:focus,a.list-group-item-warning:hover,button.list-group-item-warning:focus,button.list-group-item-warning:hover{color:#8a6d3b;background-color:#faf2cc}a.list-group-item-warning.active,a.list-group-item-warning.active:focus,a.list-group-item-warning.active:hover,button.list-group-item-warning.active,button.list-group-item-warning.active:focus,button.list-group-item-warning.active:hover{color:#fff;background-color:#8a6d3b;border-color:#8a6d3b}.list-group-item-danger{color:#a94442;background-color:#f2dede}a.list-group-item-danger,button.list-group-item-danger{color:#a94442}a.list-group-item-danger .list-group-item-heading,button.list-group-item-danger .list-group-item-heading{color:inherit}a.list-group-item-danger:focus,a.list-group-item-danger:hover,button.list-group-item-danger:focus,button.list-group-item-danger:hover{color:#a94442;background-color:#ebcccc}a.list-group-item-danger.active,a.list-group-item-danger.active:focus,a.list-group-item-danger.active:hover,button.list-group-item-danger.active,button.list-group-item-danger.active:focus,button.list-group-item-danger.active:hover{color:#fff;background-color:#a94442;border-color:#a94442}.list-group-item-heading{margin-top:0;margin-bottom:5px}.list-group-item-text{margin-bottom:0;line-height:1.3}.panel{margin-bottom:20px;background-color:#fff;border:1px solid transparent;border-radius:4px;-webkit-box-shadow:0 1px 1px rgba(0,0,0,.05);box-shadow:0 1px 1px rgba(0,0,0,.05)}.panel-body{padding:15px}.panel-heading{padding:10px 15px;border-bottom:1px solid transparent;border-top-left-radius:3px;border-top-right-radius:3px}.panel-heading>.dropdown .dropdown-toggle{color:inherit}.panel-title{margin-top:0;margin-bottom:0;font-size:16px;color:inherit}.panel-title>.small,.panel-title>.small>a,.panel-title>a,.panel-title>small,.panel-title>small>a{color:inherit}.panel-footer{padding:10px 15px;background-color:#f5f5f5;border-top:1px solid #ddd;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.list-group,.panel>.panel-collapse>.list-group{margin-bottom:0}.panel>.list-group .list-group-item,.panel>.panel-collapse>.list-group .list-group-item{border-width:1px 0;border-radius:0}.panel>.list-group:first-child .list-group-item:first-child,.panel>.panel-collapse>.list-group:first-child .list-group-item:first-child{border-top:0;border-top-left-radius:3px;border-top-right-radius:3px}.panel>.list-group:last-child .list-group-item:last-child,.panel>.panel-collapse>.list-group:last-child .list-group-item:last-child{border-bottom:0;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.panel-heading+.panel-collapse>.list-group .list-group-item:first-child{border-top-left-radius:0;border-top-right-radius:0}.panel-heading+.list-group .list-group-item:first-child{border-top-width:0}.list-group+.panel-footer{border-top-width:0}.panel>.panel-collapse>.table,.panel>.table,.panel>.table-responsive>.table{margin-bottom:0}.panel>.panel-collapse>.table caption,.panel>.table caption,.panel>.table-responsive>.table caption{padding-right:15px;padding-left:15px}.panel>.table-responsive:first-child>.table:first-child,.panel>.table:first-child{border-top-left-radius:3px;border-top-right-radius:3px}.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child,.panel>.table:first-child>thead:first-child>tr:first-child{border-top-left-radius:3px;border-top-right-radius:3px}.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child td:first-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child th:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child td:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child th:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child td:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child th:first-child,.panel>.table:first-child>thead:first-child>tr:first-child td:first-child,.panel>.table:first-child>thead:first-child>tr:first-child th:first-child{border-top-left-radius:3px}.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child td:last-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child th:last-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child td:last-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child th:last-child,.panel>.table:first-child>tbody:first-child>tr:first-child td:last-child,.panel>.table:first-child>tbody:first-child>tr:first-child th:last-child,.panel>.table:first-child>thead:first-child>tr:first-child td:last-child,.panel>.table:first-child>thead:first-child>tr:first-child th:last-child{border-top-right-radius:3px}.panel>.table-responsive:last-child>.table:last-child,.panel>.table:last-child{border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child,.panel>.table:last-child>tbody:last-child>tr:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child{border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child td:first-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child th:first-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child td:first-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child th:first-child,.panel>.table:last-child>tbody:last-child>tr:last-child td:first-child,.panel>.table:last-child>tbody:last-child>tr:last-child th:first-child,.panel>.table:last-child>tfoot:last-child>tr:last-child td:first-child,.panel>.table:last-child>tfoot:last-child>tr:last-child th:first-child{border-bottom-left-radius:3px}.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child td:last-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child th:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child td:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child th:last-child,.panel>.table:last-child>tbody:last-child>tr:last-child td:last-child,.panel>.table:last-child>tbody:last-child>tr:last-child th:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child td:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child th:last-child{border-bottom-right-radius:3px}.panel>.panel-body+.table,.panel>.panel-body+.table-responsive,.panel>.table+.panel-body,.panel>.table-responsive+.panel-body{border-top:1px solid #ddd}.panel>.table>tbody:first-child>tr:first-child td,.panel>.table>tbody:first-child>tr:first-child th{border-top:0}.panel>.table-bordered,.panel>.table-responsive>.table-bordered{border:0}.panel>.table-bordered>tbody>tr>td:first-child,.panel>.table-bordered>tbody>tr>th:first-child,.panel>.table-bordered>tfoot>tr>td:first-child,.panel>.table-bordered>tfoot>tr>th:first-child,.panel>.table-bordered>thead>tr>td:first-child,.panel>.table-bordered>thead>tr>th:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:first-child,.panel>.table-responsive>.table-bordered>thead>tr>td:first-child,.panel>.table-responsive>.table-bordered>thead>tr>th:first-child{border-left:0}.panel>.table-bordered>tbody>tr>td:last-child,.panel>.table-bordered>tbody>tr>th:last-child,.panel>.table-bordered>tfoot>tr>td:last-child,.panel>.table-bordered>tfoot>tr>th:last-child,.panel>.table-bordered>thead>tr>td:last-child,.panel>.table-bordered>thead>tr>th:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:last-child,.panel>.table-responsive>.table-bordered>thead>tr>td:last-child,.panel>.table-responsive>.table-bordered>thead>tr>th:last-child{border-right:0}.panel>.table-bordered>tbody>tr:first-child>td,.panel>.table-bordered>tbody>tr:first-child>th,.panel>.table-bordered>thead>tr:first-child>td,.panel>.table-bordered>thead>tr:first-child>th,.panel>.table-responsive>.table-bordered>tbody>tr:first-child>td,.panel>.table-responsive>.table-bordered>tbody>tr:first-child>th,.panel>.table-responsive>.table-bordered>thead>tr:first-child>td,.panel>.table-responsive>.table-bordered>thead>tr:first-child>th{border-bottom:0}.panel>.table-bordered>tbody>tr:last-child>td,.panel>.table-bordered>tbody>tr:last-child>th,.panel>.table-bordered>tfoot>tr:last-child>td,.panel>.table-bordered>tfoot>tr:last-child>th,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>td,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>th,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>td,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>th{border-bottom:0}.panel>.table-responsive{margin-bottom:0;border:0}.panel-group{margin-bottom:20px}.panel-group .panel{margin-bottom:0;border-radius:4px}.panel-group .panel+.panel{margin-top:5px}.panel-group .panel-heading{border-bottom:0}.panel-group .panel-heading+.panel-collapse>.list-group,.panel-group .panel-heading+.panel-collapse>.panel-body{border-top:1px solid #ddd}.panel-group .panel-footer{border-top:0}.panel-group .panel-footer+.panel-collapse .panel-body{border-bottom:1px solid #ddd}.panel-default{border-color:#ddd}.panel-default>.panel-heading{color:#333;background-color:#f5f5f5;border-color:#ddd}.panel-default>.panel-heading+.panel-collapse>.panel-body{border-top-color:#ddd}.panel-default>.panel-heading .badge{color:#f5f5f5;background-color:#333}.panel-default>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#ddd}.panel-primary{border-color:#337ab7}.panel-primary>.panel-heading{color:#fff;background-color:#337ab7;border-color:#337ab7}.panel-primary>.panel-heading+.panel-collapse>.panel-body{border-top-color:#337ab7}.panel-primary>.panel-heading .badge{color:#337ab7;background-color:#fff}.panel-primary>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#337ab7}.panel-success{border-color:#d6e9c6}.panel-success>.panel-heading{color:#3c763d;background-color:#dff0d8;border-color:#d6e9c6}.panel-success>.panel-heading+.panel-collapse>.panel-body{border-top-color:#d6e9c6}.panel-success>.panel-heading .badge{color:#dff0d8;background-color:#3c763d}.panel-success>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#d6e9c6}.panel-info{border-color:#bce8f1}.panel-info>.panel-heading{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.panel-info>.panel-heading+.panel-collapse>.panel-body{border-top-color:#bce8f1}.panel-info>.panel-heading .badge{color:#d9edf7;background-color:#31708f}.panel-info>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#bce8f1}.panel-warning{border-color:#faebcc}.panel-warning>.panel-heading{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}.panel-warning>.panel-heading+.panel-collapse>.panel-body{border-top-color:#faebcc}.panel-warning>.panel-heading .badge{color:#fcf8e3;background-color:#8a6d3b}.panel-warning>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#faebcc}.panel-danger{border-color:#ebccd1}.panel-danger>.panel-heading{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.panel-danger>.panel-heading+.panel-collapse>.panel-body{border-top-color:#ebccd1}.panel-danger>.panel-heading .badge{color:#f2dede;background-color:#a94442}.panel-danger>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#ebccd1}.embed-responsive{position:relative;display:block;height:0;padding:0;overflow:hidden}.embed-responsive .embed-responsive-item,.embed-responsive embed,.embed-responsive iframe,.embed-responsive object,.embed-responsive video{position:absolute;top:0;bottom:0;left:0;width:100%;height:100%;border:0}.embed-responsive-16by9{padding-bottom:56.25%}.embed-responsive-4by3{padding-bottom:75%}.well{min-height:20px;padding:19px;margin-bottom:20px;background-color:#f5f5f5;border:1px solid #e3e3e3;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.05);box-shadow:inset 0 1px 1px rgba(0,0,0,.05)}.well blockquote{border-color:#ddd;border-color:rgba(0,0,0,.15)}.well-lg{padding:24px;border-radius:6px}.well-sm{padding:9px;border-radius:3px}.close{float:right;font-size:21px;font-weight:700;line-height:1;color:#000;text-shadow:0 1px 0 #fff;filter:alpha(opacity=20);opacity:.2}.close:focus,.close:hover{color:#000;text-decoration:none;cursor:pointer;filter:alpha(opacity=50);opacity:.5}button.close{padding:0;cursor:pointer;background:0 0;border:0;-webkit-appearance:none;-moz-appearance:none;appearance:none}.modal-open{overflow:hidden}.modal{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1050;display:none;overflow:hidden;-webkit-overflow-scrolling:touch;outline:0}.modal.fade .modal-dialog{-webkit-transform:translate(0,-25%);-ms-transform:translate(0,-25%);-o-transform:translate(0,-25%);transform:translate(0,-25%);-webkit-transition:-webkit-transform .3s ease-out;-o-transition:-o-transform .3s ease-out;transition:-webkit-transform .3s ease-out;transition:transform .3s ease-out;transition:transform .3s ease-out,-webkit-transform .3s ease-out,-o-transform .3s ease-out}.modal.in .modal-dialog{-webkit-transform:translate(0,0);-ms-transform:translate(0,0);-o-transform:translate(0,0);transform:translate(0,0)}.modal-open .modal{overflow-x:hidden;overflow-y:auto}.modal-dialog{position:relative;width:auto;margin:10px}.modal-content{position:relative;background-color:#fff;background-clip:padding-box;border:1px solid #999;border:1px solid rgba(0,0,0,.2);border-radius:6px;-webkit-box-shadow:0 3px 9px rgba(0,0,0,.5);box-shadow:0 3px 9px rgba(0,0,0,.5);outline:0}.modal-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1040;background-color:#000}.modal-backdrop.fade{filter:alpha(opacity=0);opacity:0}.modal-backdrop.in{filter:alpha(opacity=50);opacity:.5}.modal-header{padding:15px;border-bottom:1px solid #e5e5e5}.modal-header .close{margin-top:-2px}.modal-title{margin:0;line-height:1.42857143}.modal-body{position:relative;padding:15px}.modal-footer{padding:15px;text-align:right;border-top:1px solid #e5e5e5}.modal-footer .btn+.btn{margin-bottom:0;margin-left:5px}.modal-footer .btn-group .btn+.btn{margin-left:-1px}.modal-footer .btn-block+.btn-block{margin-left:0}.modal-scrollbar-measure{position:absolute;top:-9999px;width:50px;height:50px;overflow:scroll}@media (min-width:768px){.modal-dialog{width:600px;margin:30px auto}.modal-content{-webkit-box-shadow:0 5px 15px rgba(0,0,0,.5);box-shadow:0 5px 15px rgba(0,0,0,.5)}.modal-sm{width:300px}}@media (min-width:992px){.modal-lg{width:900px}}.tooltip{position:absolute;z-index:1070;display:block;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-style:normal;font-weight:400;line-height:1.42857143;line-break:auto;text-align:left;text-align:start;text-decoration:none;text-shadow:none;text-transform:none;letter-spacing:normal;word-break:normal;word-spacing:normal;word-wrap:normal;white-space:normal;font-size:12px;filter:alpha(opacity=0);opacity:0}.tooltip.in{filter:alpha(opacity=90);opacity:.9}.tooltip.top{padding:5px 0;margin-top:-3px}.tooltip.right{padding:0 5px;margin-left:3px}.tooltip.bottom{padding:5px 0;margin-top:3px}.tooltip.left{padding:0 5px;margin-left:-3px}.tooltip.top .tooltip-arrow{bottom:0;left:50%;margin-left:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.top-left .tooltip-arrow{right:5px;bottom:0;margin-bottom:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.top-right .tooltip-arrow{bottom:0;left:5px;margin-bottom:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.right .tooltip-arrow{top:50%;left:0;margin-top:-5px;border-width:5px 5px 5px 0;border-right-color:#000}.tooltip.left .tooltip-arrow{top:50%;right:0;margin-top:-5px;border-width:5px 0 5px 5px;border-left-color:#000}.tooltip.bottom .tooltip-arrow{top:0;left:50%;margin-left:-5px;border-width:0 5px 5px;border-bottom-color:#000}.tooltip.bottom-left .tooltip-arrow{top:0;right:5px;margin-top:-5px;border-width:0 5px 5px;border-bottom-color:#000}.tooltip.bottom-right .tooltip-arrow{top:0;left:5px;margin-top:-5px;border-width:0 5px 5px;border-bottom-color:#000}.tooltip-inner{max-width:200px;padding:3px 8px;color:#fff;text-align:center;background-color:#000;border-radius:4px}.tooltip-arrow{position:absolute;width:0;height:0;border-color:transparent;border-style:solid}.popover{position:absolute;top:0;left:0;z-index:1060;display:none;max-width:276px;padding:1px;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-style:normal;font-weight:400;line-height:1.42857143;line-break:auto;text-align:left;text-align:start;text-decoration:none;text-shadow:none;text-transform:none;letter-spacing:normal;word-break:normal;word-spacing:normal;word-wrap:normal;white-space:normal;font-size:14px;background-color:#fff;background-clip:padding-box;border:1px solid #ccc;border:1px solid rgba(0,0,0,.2);border-radius:6px;-webkit-box-shadow:0 5px 10px rgba(0,0,0,.2);box-shadow:0 5px 10px rgba(0,0,0,.2)}.popover.top{margin-top:-10px}.popover.right{margin-left:10px}.popover.bottom{margin-top:10px}.popover.left{margin-left:-10px}.popover>.arrow{border-width:11px}.popover>.arrow,.popover>.arrow:after{position:absolute;display:block;width:0;height:0;border-color:transparent;border-style:solid}.popover>.arrow:after{content:"";border-width:10px}.popover.top>.arrow{bottom:-11px;left:50%;margin-left:-11px;border-top-color:#999;border-top-color:rgba(0,0,0,.25);border-bottom-width:0}.popover.top>.arrow:after{bottom:1px;margin-left:-10px;content:" ";border-top-color:#fff;border-bottom-width:0}.popover.right>.arrow{top:50%;left:-11px;margin-top:-11px;border-right-color:#999;border-right-color:rgba(0,0,0,.25);border-left-width:0}.popover.right>.arrow:after{bottom:-10px;left:1px;content:" ";border-right-color:#fff;border-left-width:0}.popover.bottom>.arrow{top:-11px;left:50%;margin-left:-11px;border-top-width:0;border-bottom-color:#999;border-bottom-color:rgba(0,0,0,.25)}.popover.bottom>.arrow:after{top:1px;margin-left:-10px;content:" ";border-top-width:0;border-bottom-color:#fff}.popover.left>.arrow{top:50%;right:-11px;margin-top:-11px;border-right-width:0;border-left-color:#999;border-left-color:rgba(0,0,0,.25)}.popover.left>.arrow:after{right:1px;bottom:-10px;content:" ";border-right-width:0;border-left-color:#fff}.popover-title{padding:8px 14px;margin:0;font-size:14px;background-color:#f7f7f7;border-bottom:1px solid #ebebeb;border-radius:5px 5px 0 0}.popover-content{padding:9px 14px}.carousel{position:relative}.carousel-inner{position:relative;width:100%;overflow:hidden}.carousel-inner>.item{position:relative;display:none;-webkit-transition:.6s ease-in-out left;-o-transition:.6s ease-in-out left;transition:.6s ease-in-out left}.carousel-inner>.item>a>img,.carousel-inner>.item>img{line-height:1}@media all and (transform-3d),(-webkit-transform-3d){.carousel-inner>.item{-webkit-transition:-webkit-transform .6s ease-in-out;-o-transition:-o-transform .6s ease-in-out;transition:-webkit-transform .6s ease-in-out;transition:transform .6s ease-in-out;transition:transform .6s ease-in-out,-webkit-transform .6s ease-in-out,-o-transform .6s ease-in-out;-webkit-backface-visibility:hidden;backface-visibility:hidden;-webkit-perspective:1000px;perspective:1000px}.carousel-inner>.item.active.right,.carousel-inner>.item.next{-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0);left:0}.carousel-inner>.item.active.left,.carousel-inner>.item.prev{-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0);left:0}.carousel-inner>.item.active,.carousel-inner>.item.next.left,.carousel-inner>.item.prev.right{-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0);left:0}}.carousel-inner>.active,.carousel-inner>.next,.carousel-inner>.prev{display:block}.carousel-inner>.active{left:0}.carousel-inner>.next,.carousel-inner>.prev{position:absolute;top:0;width:100%}.carousel-inner>.next{left:100%}.carousel-inner>.prev{left:-100%}.carousel-inner>.next.left,.carousel-inner>.prev.right{left:0}.carousel-inner>.active.left{left:-100%}.carousel-inner>.active.right{left:100%}.carousel-control{position:absolute;top:0;bottom:0;left:0;width:15%;font-size:20px;color:#fff;text-align:center;text-shadow:0 1px 2px rgba(0,0,0,.6);background-color:rgba(0,0,0,0);filter:alpha(opacity=50);opacity:.5}.carousel-control.left{background-image:-webkit-linear-gradient(left,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);background-image:-o-linear-gradient(left,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);background-image:-webkit-gradient(linear,left top,right top,from(rgba(0,0,0,.5)),to(rgba(0,0,0,.0001)));background-image:linear-gradient(to right,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1);background-repeat:repeat-x}.carousel-control.right{right:0;left:auto;background-image:-webkit-linear-gradient(left,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);background-image:-o-linear-gradient(left,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);background-image:-webkit-gradient(linear,left top,right top,from(rgba(0,0,0,.0001)),to(rgba(0,0,0,.5)));background-image:linear-gradient(to right,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1);background-repeat:repeat-x}.carousel-control:focus,.carousel-control:hover{color:#fff;text-decoration:none;outline:0;filter:alpha(opacity=90);opacity:.9}.carousel-control .glyphicon-chevron-left,.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next,.carousel-control .icon-prev{position:absolute;top:50%;z-index:5;display:inline-block;margin-top:-10px}.carousel-control .glyphicon-chevron-left,.carousel-control .icon-prev{left:50%;margin-left:-10px}.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next{right:50%;margin-right:-10px}.carousel-control .icon-next,.carousel-control .icon-prev{width:20px;height:20px;font-family:serif;line-height:1}.carousel-control .icon-prev:before{content:"\2039"}.carousel-control .icon-next:before{content:"\203a"}.carousel-indicators{position:absolute;bottom:10px;left:50%;z-index:15;width:60%;padding-left:0;margin-left:-30%;text-align:center;list-style:none}.carousel-indicators li{display:inline-block;width:10px;height:10px;margin:1px;text-indent:-999px;cursor:pointer;background-color:#000\9;background-color:rgba(0,0,0,0);border:1px solid #fff;border-radius:10px}.carousel-indicators .active{width:12px;height:12px;margin:0;background-color:#fff}.carousel-caption{position:absolute;right:15%;bottom:20px;left:15%;z-index:10;padding-top:20px;padding-bottom:20px;color:#fff;text-align:center;text-shadow:0 1px 2px rgba(0,0,0,.6)}.carousel-caption .btn{text-shadow:none}@media screen and (min-width:768px){.carousel-control .glyphicon-chevron-left,.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next,.carousel-control .icon-prev{width:30px;height:30px;margin-top:-10px;font-size:30px}.carousel-control .glyphicon-chevron-left,.carousel-control .icon-prev{margin-left:-10px}.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next{margin-right:-10px}.carousel-caption{right:20%;left:20%;padding-bottom:30px}.carousel-indicators{bottom:20px}}.btn-group-vertical>.btn-group:after,.btn-group-vertical>.btn-group:before,.btn-toolbar:after,.btn-toolbar:before,.clearfix:after,.clearfix:before,.container-fluid:after,.container-fluid:before,.container:after,.container:before,.dl-horizontal dd:after,.dl-horizontal dd:before,.form-horizontal .form-group:after,.form-horizontal .form-group:before,.modal-footer:after,.modal-footer:before,.modal-header:after,.modal-header:before,.nav:after,.nav:before,.navbar-collapse:after,.navbar-collapse:before,.navbar-header:after,.navbar-header:before,.navbar:after,.navbar:before,.pager:after,.pager:before,.panel-body:after,.panel-body:before,.row:after,.row:before{display:table;content:" "}.btn-group-vertical>.btn-group:after,.btn-toolbar:after,.clearfix:after,.container-fluid:after,.container:after,.dl-horizontal dd:after,.form-horizontal .form-group:after,.modal-footer:after,.modal-header:after,.nav:after,.navbar-collapse:after,.navbar-header:after,.navbar:after,.pager:after,.panel-body:after,.row:after{clear:both}.center-block{display:block;margin-right:auto;margin-left:auto}.pull-right{float:right!important}.pull-left{float:left!important}.hide{display:none!important}.show{display:block!important}.invisible{visibility:hidden}.text-hide{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0}.hidden{display:none!important}.affix{position:fixed}@-ms-viewport{width:device-width}.visible-lg,.visible-md,.visible-sm,.visible-xs{display:none!important}.visible-lg-block,.visible-lg-inline,.visible-lg-inline-block,.visible-md-block,.visible-md-inline,.visible-md-inline-block,.visible-sm-block,.visible-sm-inline,.visible-sm-inline-block,.visible-xs-block,.visible-xs-inline,.visible-xs-inline-block{display:none!important}@media (max-width:767px){.visible-xs{display:block!important}table.visible-xs{display:table!important}tr.visible-xs{display:table-row!important}td.visible-xs,th.visible-xs{display:table-cell!important}}@media (max-width:767px){.visible-xs-block{display:block!important}}@media (max-width:767px){.visible-xs-inline{display:inline!important}}@media (max-width:767px){.visible-xs-inline-block{display:inline-block!important}}@media (min-width:768px) and (max-width:991px){.visible-sm{display:block!important}table.visible-sm{display:table!important}tr.visible-sm{display:table-row!important}td.visible-sm,th.visible-sm{display:table-cell!important}}@media (min-width:768px) and (max-width:991px){.visible-sm-block{display:block!important}}@media (min-width:768px) and (max-width:991px){.visible-sm-inline{display:inline!important}}@media (min-width:768px) and (max-width:991px){.visible-sm-inline-block{display:inline-block!important}}@media (min-width:992px) and (max-width:1199px){.visible-md{display:block!important}table.visible-md{display:table!important}tr.visible-md{display:table-row!important}td.visible-md,th.visible-md{display:table-cell!important}}@media (min-width:992px) and (max-width:1199px){.visible-md-block{display:block!important}}@media (min-width:992px) and (max-width:1199px){.visible-md-inline{display:inline!important}}@media (min-width:992px) and (max-width:1199px){.visible-md-inline-block{display:inline-block!important}}@media (min-width:1200px){.visible-lg{display:block!important}table.visible-lg{display:table!important}tr.visible-lg{display:table-row!important}td.visible-lg,th.visible-lg{display:table-cell!important}}@media (min-width:1200px){.visible-lg-block{display:block!important}}@media (min-width:1200px){.visible-lg-inline{display:inline!important}}@media (min-width:1200px){.visible-lg-inline-block{display:inline-block!important}}@media (max-width:767px){.hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.hidden-md{display:none!important}}@media (min-width:1200px){.hidden-lg{display:none!important}}.visible-print{display:none!important}@media print{.visible-print{display:block!important}table.visible-print{display:table!important}tr.visible-print{display:table-row!important}td.visible-print,th.visible-print{display:table-cell!important}}.visible-print-block{display:none!important}@media print{.visible-print-block{display:block!important}}.visible-print-inline{display:none!important}@media print{.visible-print-inline{display:inline!important}}.visible-print-inline-block{display:none!important}@media print{.visible-print-inline-block{display:inline-block!important}}@media print{.hidden-print{display:none!important}} -/*# sourceMappingURL=bootstrap.min.css.map */ \ No newline at end of file diff --git a/css/main.css b/css/main.css deleted file mode 100644 index 41fad38..0000000 --- a/css/main.css +++ /dev/null @@ -1,685 +0,0 @@ -@import url('https://fonts.googleapis.com/css?family=Open+Sans:400&subset=cyrillic,cyrillic-ext,greek,greek-ext,latin-ext,vietnamese'); -@import url('https://fonts.googleapis.com/css?family=Fira+Sans:400,700&subset=cyrillic,cyrillic-ext,greek,greek-ext,latin-ext,vietnamese'); - -body { - background: #ffffff; - margin: 0; - margin-top: 80px; - height: 100%; - line-height: 24px; - font-family: 'Open Sans', sans-serif; -} - -img { - height: auto; - max-width: 100%; -} - -a { - padding: 0; - margin: 0; - text-decoration: none; -} - -a:hover, -a:focus { - text-decoration: none; - color:#f5f4f4; -} - -a.desc-tool-tip, a.desc-tool-tip:hover, a.desc-tool-tip:visited { - color: grey; -} - -.centered { - text-align: center -} - - -.navbar { - padding-top: 5px; - margin-bottom: 0px; -} - -.navbar-brand { - padding: 10px 15px; -} - - -.navbar-default .navbar-nav > li > a { - color: #f5f4f4; - font-size: 1em; -} - -.navbar-default .navbar-nav > li > a:hover { - color: #a7a7a7; -} - -.navbar-default .navbar-nav > .active > a, .navbar-default .navbar-nav > .active > a:hover, .navbar-default .navbar-nav > .active > a:focus { - color: #f5f4f4; - background-color: transparent; -} -.navbar-collapse -{ - background: gray; -} -.navbar-default { - z-index: 200; - background-color: gray; - border-color: transparent; - border-radius: 0px 0px 30px 30px; - height: 77px; - position: fixed; - top: 0; - width: 100%; -} -.admins_color h4 { - color: #3a72bd; - font-weight: bold; -} - - -.navbar-right{ - margin-top: 15px; -} - -.navbar-left{ - margin-top: 8px; -} - -div.center { - margin-left: auto; - margin-right: auto; -} - -#wrapper -{ - max-width: 1024px; - min-height: calc(100vh - 157px); - padding-right: 15px; - padding-left: 15px -} - -#status-container -{ - border-radius: 5px; - border: 1px solid #e0e0e0; -} - -#status-container .item:last-child -{ - border: none; -} - -#status-container .item{ - border-bottom: 1px solid #e0e0e0; -} - -.service{ - float: left; - box-sizing: border-box; - padding: 15px 35px; - font-weight: bold; - font-size: 1.1em; - font-family: 'Fira Sans', sans-serif; -} - -body a h1{ - font-size: 1.3em; - margin: 0; - line-height: 1.3em -} - -.status{ - float: right; - box-sizing: border-box; - padding: 0px 35px; - text-align: right; - font-size: 1.05em; - font-family: 'Fira Sans', sans-serif; -} - -.status.success{ - color:#2fcc66; -} - -.status.warning{ - color:#edaa16; -} - -.status.danger{ - color:#e74c3c; -} - -.status.primary{ - color:#3A72BD; -} - -.panel-success{ - border-color:#2fcc66; -} - -.navbar-header .btn -{ - margin-top: 15px; - margin-right: 10px -} - -.panel-warning{ - border-color:#edaa16; -} - -.panel-danger{ - border-color:#e74c3c; -} - -.panel-success .panel-heading, #status-big.success{ - background: #2fcc66; - border-color: rgba(0, 0, 0, 0.1); -} -.panel-warning .panel-heading, #status-big.warning{ - background:#edaa16; - border-color: rgba(0, 0, 0, 0.1); -} - -.panel-danger .panel-heading, #status-big.danger{ - background:#e74c3c; - border-color: rgba(0, 0, 0, 0.1); -} - -#status-big.primary{ - background: #3A72BD; -} - -#wrapper .panel-heading{ - color:white; -} - -#status-big{ - width: 100%; - margin-bottom:15px; - float: none; - color: white; - text-align: left; - padding: 15px; - border-radius: 5px; - font-size: 1.3em; - font-family: 'Fira Sans', sans-serif; -} - -.timeline { - position: relative; - padding: 0 0px 10px; - margin-top: 4px; -} - -.timeline .line { - position: absolute; - width: 2px; - display: block; - background: #c2c2c2; - top: 0px; - bottom: 0px; - margin-left: 31px; -} - -.timeline .panel { - position: relative; - margin: 10px 0px 21px 70px; - clear: both; -} - -.timeline .panel::before { - position: absolute; - display: block; - top: 8px; - left: -24px; - content: ''; - width: 0px; - height: 0px; - border: inherit; - border-width: 12px; - border-top-color: transparent; - border-bottom-color: transparent; - border-left-color: transparent; -} - -.timeline .panel .panel-heading.icon * { - /*This shouldn't be relative in size...*/ - font-size: 20px; - vertical-align: middle; - line-height: 40px; -} -.timeline .panel .panel-heading.icon { - position: absolute; - left: -59px; - display: block; - width: 40px; - height: 40px; - padding: 0px; - border-radius: 50%; - text-align: center; - float: left; -} - -.timeline .panel-outline { - border-color: transparent; - background: transparent; - box-shadow: none; -} - -.timeline .panel-outline .panel-body { - padding: 10px 0px; -} - -.timeline .panel-outline .panel-heading:not(.icon), -.timeline .panel-outline .panel-footer { - display: none; -} - -.timeline .line::before { top: -4px; } -.timeline .line::before{ - content: ''; - position: absolute; - left: -4px; - width: 10px; - height: 10px; - display: block; - border-radius: 50%; - background: #c2c2c2; -} - - -.panel-heading h2 -{ - display: inline-block; -} - -/* Footer */ -#footerwrap { - border-radius: 30px 30px 0px 0px; - min-height: 60px; - padding-top: 15px; - padding-bottom: 10px; - background: gray; -} - -#footerwrap a{ - color: #6daddc; -} - -#footerwrap a:hover{ - color: #a4ceea; -} - - - -#footerwrap p { - color: #e5e5e5; - margin-top: 4px; -} - -#footerwrap h4 { - color: white; -} - -#footerwrap i { - font-size: 1.7em; - color: #ebebeb; - padding-right: 15px; -} - -#footerwrap i:hover { - color: #c5c5c5; -} - -#footerwrap .col-md-4, #footerwrap .col-md-8 { - color: #e5e5e5; - margin-top: 4px; -} - -#footerwrap .col-md-4{ - margin-top: 2px; -} - -@media (max-width: 991px) { - body #footerwrap .col-md-8, #footerwrap .col-md-4 { - text-align: center; - } -} - -#timeline{ - padding-top: 50px -} - -#timeline h3{ - margin-top: 40px; - padding-left: 70px; - margin-bottom: 15px -} - -#login-form{ - max-width: 500px; - padding-top: 20px -} - -.navbar-right.navbar-admin -{ - margin-top: 10px -} - -.panel-footer input, .panel-heading input{ - background: transparent; - border: none; - border-bottom: 1px solid #777; -} - -.panel-footer input.error, .panel-heading input.error{ - border-bottom: 1px solid red; - color: red; -} - -input, textarea -{ - outline: none -} - -/*Stupid chrome can't have this in one selector...*/ -body .panel-heading input::-webkit-input-placeholder -{ - color:white; -} - -body .panel-heading input::-moz-placeholder -{ - color:white; -} - -body .panel-heading input:-ms-input-placeholder -{ - color:white; -} - -body .panel-heading input:-moz-placeholder -{ - color:white; -} - -body .panel-heading input::placeholder{ - color:white; -} - - -.panel.panel-primary input#title{ - width: 50%; -} - -#time input { - max-width: 100% -} -.panel.panel-primary #time{ - display: inline-block; - float: right; - width: 40%; - max-width: 40% -} - -.panel.panel-primary input#title{ - width: 50%; - max-width: 50% -} - -.panel:not(.panel-primary) input#title{ - width: 100%; -} - -.panel:not(.panel-primary) #time, -.panel:not(.panel-primary) #end_time_wrapper{ - display: none; -} - -#time::-moz-placeholder, #title::-moz-placeholder { - opacity: 1; -} - -.panel-body textarea -{ - width: 100%; - background: transparent; - border: none; - resize: vertical; - min-height: 100px -} - -#type -{ - max-width: 200px; - margin-left: 70px -} - -#wrapper.admin #timeline{ - padding-top: 0 -} - -#wrapper.admin #timeline .service{ - padding-left: 15px -} - - -#wrapper.admin #timeline .service input[type=checkbox]{ - margin-right: 4px; - margin-top: 0; - vertical-align: middle; -} - -body.admin table td{ - word-break: break-all; -} - -section{ - padding-top: 20px; -} - -section h3{ - margin: 0; - margin-bottom: 20px; - line-height: 34px; -} - -i.success{ - color:#2fcc66; -} - -i.danger{ - color:#e74c3c; -} - -.col-md-2 strong{ - line-height: 34px -} - -.table-responsive{ - width:100%; -} - -.col-md-6{ - line-height: 34px -} - -.margin-top{ - margin-top: 10px -} - -#status-container.error input -{ - box-shadow: 0px 0 2px 1px rgba(255,0,0,1) -} - -.delete -{ - margin-left: 5px; - font-size: 1.2em; - color: white; - line-height: 25px -} - -.delete:hover, .delete:focus -{ - color: #EEE -} - -.new-service{ - width: 40%; - min-width: 250px; -} - -.delete-service -{ - color: red; - font-size: 1em -} - -.service label -{ - margin-bottom: 0 -} - -.install{ - padding-bottom: 25px -} - -.install .btn -{ - margin-top: 30px -} - -.text-left{ - text-align: left; -} - -.text-right{ - text-align: right; -} - -.text-center{ - text-align: center; -} - -#footerwrap .dropdown-menu{ - background: gray; -} - -#footerwrap .dropdown-menu a{ - color:white; - width: 100%; - padding: 2px 5px; - display: block; - transition: 125ms ease-in-out background-color; - background-color: gray; -} - -#footerwrap .dropdown-menu a:hover{ - background-color: #2f8ad8; -} - -#footerwrap .btn-group.dropup img{ - max-height: 20px; - max-width: 25px; - margin-right: 5px; - vertical-align: middle; -} - -.col-md-4.text-left, .col-md-4.text-right{ - line-height: 2.5; -} - -.dropup hr.divider -{ - margin: 2px; - border: 1px; -} - -body .h1,body .h2,body .h3,body h1,body h2,body h3 { - margin-top: 18px; -} - -.row.user .input-group -{ - width: 100%; - margin-bottom: 5px -} - -.row.user .form-name{ - width: 50%; - float: left; -} - -label.form-name -{ - line-height: 20px -} -.panel .panel-footer .label{ - display: inline-block; -} -/* The switch - the box around the slider */ -.switch { - position: relative; - display: inline-block; - width: 60px; - height: 34px; -} - -/* Hide default HTML checkbox */ -.switch input { - opacity: 0; - width: 0; - height: 0; -} - -/* The slider */ -.slider { - position: absolute; - cursor: pointer; - top: 0; - left: 0; - right: 0; - bottom: 0; - background-color: #ccc; - -webkit-transition: .4s; - transition: .4s; -} - -.slider:before { - position: absolute; - content: ""; - height: 26px; - width: 26px; - left: 4px; - bottom: 4px; - background-color: white; - -webkit-transition: .4s; - transition: .4s; -} - -input:checked + .slider { - background-color: #2196F3; -} - -input:focus + .slider { - box-shadow: 0 0 1px #2196F3; -} - -input:checked + .slider:before { - -webkit-transform: translateX(26px); - -ms-transform: translateX(26px); - transform: translateX(26px); -} - -/* Rounded sliders */ -.slider.round { - border-radius: 34px; -} - -.slider.round:before { - border-radius: 50%; -} diff --git a/css/print.css b/css/print.css deleted file mode 100644 index d688d07..0000000 --- a/css/print.css +++ /dev/null @@ -1,140 +0,0 @@ -@import url(https://fonts.googleapis.com/css?family=Open+Sans:400); -@import url(https://fonts.googleapis.com/css?family=Fira+Sans:400,700); - -body { - background: #ffffff; - margin: 0; - height: 100%; - line-height: 24px; - font-family: 'Open Sans', sans-serif; -} - -#status-container -{ - border-radius: 0; - border-top: 1px solid #e0e0e0; - border-bottom: 1px solid #e0e0e0; -} - -#status-container .item:last-child -{ - border: none; -} - -#status-container .item{ - border-bottom: 1px solid #e0e0e0; -} - -#status-big -{ - float: none; - width: 100%; - text-align: center; - font-family: 'Fira Sans', sans-serif; - font-size: 1.5em -} - -#wrapper{ - padding-left: 20%; - padding-right: 20%; -} - -.service{ - float: left; - box-sizing: border-box; - width:60%; - min-width: 200px; - padding: 15px 35px; - font-weight: bold; - font-size: 1em; - font-family: 'Fira Sans', sans-serif; -} - -.status{ - float: left; - box-sizing: border-box; - width:40%; - min-width: 150px; - padding: 15px 35px; - text-align: right; - font-size: 0.8em; - font-family: 'Fira Sans', sans-serif; -} - - -#status-container .status.success{ - color:#2fcc66!important; - font-weight: bolder; -} - -#status-container .status.warning{ - color:#edaa16!important; - font-weight: bolder; -} - -#status-container .status.danger{ - color:#e74c3c!important; - font-weight: bolder; -} - -#status-container .status.primary{ - color:#3A72BD!important; - font-weight: bolder; -} - -.panel-success{ - border-color:#2fcc66; -} -#footerwrap{ - display: none -} -.btn -{ - display: none -} - -h3{ - text-align: center; -} - -.panel-heading.icon{ - width: 50px; - float: left; - border: none; -} - -h2.panel-title{ - float: left; -} - -.panel,.panel-heading,.panel-footer{ - border-width: 3px -} - -body .panel-danger, -.panel-danger > .panel-body, -.panel-danger > .panel-heading, -.panel-danger > .panel-footer{ - border-color: #a94442 -} - -body .panel-success, -.panel-success > .panel-body, -.panel-success > .panel-heading, -.panel-success > .panel-footer{ - border-color: #2fcc66 -} - -body .panel-warning, -.panel-warning > .panel-body, -.panel-warning > .panel-heading, -.panel-warning > .panel-footer{ - border-color: #edaa16 -} - -body .panel-primary, -.panel-primary > .panel-body, -.panel-primary > .panel-heading, -.panel-primary > .panel-footer{ - border-color: #337ab7 -} \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..33fc5da --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,25 @@ +version: '2' +services: + server-status-php: + container_name: server-status-php + build: docker/php + volumes: + - ./src/:/app + - /etc/localtime:/etc/localtime:ro + working_dir: /app + ports: + - "80:80" + - "443:443" + links: + - "server-status-mysql" + environment: + - DOCKER_DEVELOPMENT=1 + + server-status-mysql: + container_name: server-status-mysql + build: docker/mysql + volumes: + - /etc/localtime:/etc/localtime:ro + environment: + - MYSQL_DATABASE=server-status + - MYSQL_ROOT_PASSWORD=root \ No newline at end of file diff --git a/docker/helper.sh b/docker/helper.sh new file mode 100755 index 0000000..7c5c78d --- /dev/null +++ b/docker/helper.sh @@ -0,0 +1,44 @@ +#!/bin/bash + +NC='\033[0m' # No Color +RED='\033[0;31m' +GREEN='\033[0;32m' +ORANGE='\033[0;33m' +APP_CONTAINER='server-status-php' + +function renderHelp() { + echo -e "${GREEN}Console tool${NC}" + echo "" + echo -e "${ORANGE}Available commands for localhost environment:${NC}" + echo -e " ${GREEN}up${NC} Start development environment." + echo -e " ${GREEN}down${NC} Stop development environment." + echo "" + echo -e "${ORANGE}Available commands in container:${NC}" + echo -e " ${GREEN}test-unit${NC} Tests - unit tests." + exit 0; +} + + +function composeUp() { + MYSQL_HOST='server-status-mysql' + MYSQL_USER='root' + MYSQL_PASS='root' + MYSQL_DB='server-status' + cp config/config.php src/config.php + docker compose up -d --build; + until docker compose run server-status-php mysql -h ${MYSQL_HOST} -u ${MYSQL_USER} -p${MYSQL_PASS} -e ""; do + >&2 echo "MySQL is unavailable, waiting for it to start."; + sleep 2; + done; + docker compose run server-status-php \ + mysql \ + -h ${MYSQL_HOST} \ + -u ${MYSQL_USER} \ + -p${MYSQL_PASS} server-status < sql/demo.sql; + echo "==== Environment ready! ===="; +} + + +function composeDown() { + docker compose down; +} \ No newline at end of file diff --git a/docker/mysql/Dockerfile b/docker/mysql/Dockerfile new file mode 100755 index 0000000..c191169 --- /dev/null +++ b/docker/mysql/Dockerfile @@ -0,0 +1,3 @@ +FROM mariadb:10.6 + +RUN echo "Europe/Prague" > /etc/timezone diff --git a/docker/php/Dockerfile b/docker/php/Dockerfile new file mode 100755 index 0000000..0e88ce9 --- /dev/null +++ b/docker/php/Dockerfile @@ -0,0 +1,43 @@ +FROM php:8.0-apache + +RUN apt-get update \ + && apt-get install -y --force-yes \ + git \ + wget \ + libfreetype6-dev \ + libjpeg62-turbo-dev \ + libmcrypt-dev + +RUN apt-get install -y --force-yes mariadb-client + +RUN apt-get -y install zlib1g-dev + +RUN apt-get update -y \ + && apt-get install -y \ + libxml2-dev \ + vim \ + && apt-get clean -y + +RUN apt-get install -y libfreetype6-dev libjpeg62-turbo-dev \ + && docker-php-ext-configure gd --with-freetype --with-jpeg + +RUN docker-php-ext-install \ + mysqli \ + bcmath \ + gettext \ + gd + +RUN apt-get install -y --force-yes ssl-cert + +COPY ./conf/custom.ini /usr/local/etc/php/conf.d/custom.ini + +RUN echo "Europe/Prague" > /etc/timezone + +RUN a2enmod rewrite +RUN a2enmod ssl +RUN a2enmod headers + +COPY ./conf/server-status.localhost.conf /etc/apache2/sites-enabled/000-default.conf +COPY ./conf/ssl-default.conf /etc/apache2/sites-enabled/ssl-default.conf + +WORKDIR /app diff --git a/docker/php/conf/custom.ini b/docker/php/conf/custom.ini new file mode 100755 index 0000000..22be448 --- /dev/null +++ b/docker/php/conf/custom.ini @@ -0,0 +1,3 @@ +memory_limit = 256M +upload_max_filesize = 64M +post_max_size = 64M diff --git a/docker/php/conf/server-status.localhost.conf b/docker/php/conf/server-status.localhost.conf new file mode 100644 index 0000000..955dcc2 --- /dev/null +++ b/docker/php/conf/server-status.localhost.conf @@ -0,0 +1,14 @@ + + ServerName server-status.localhost + + DocumentRoot /app/ + + + Options Indexes FollowSymLinks MultiViews + AllowOverride All + Order allow,deny + Allow from all + Require all granted + DirectoryIndex index.php + + diff --git a/docker/php/conf/ssl-default.conf b/docker/php/conf/ssl-default.conf new file mode 100644 index 0000000..37de3d1 --- /dev/null +++ b/docker/php/conf/ssl-default.conf @@ -0,0 +1,21 @@ + + + ServerName server-status.localhost + + DocumentRoot /app/ + + SSLEngine on + SSLCertificateFile /etc/ssl/certs/ssl-cert-snakeoil.pem + SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key + SSLCACertificatePath /etc/ssl/certs/ + + + Options Indexes FollowSymLinks MultiViews + AllowOverride All + Order allow,deny + Allow from all + Require all granted + DirectoryIndex index.php + + + diff --git a/email_subscriptions.php b/email_subscriptions.php deleted file mode 100644 index 366c2be..0000000 --- a/email_subscriptions.php +++ /dev/null @@ -1,219 +0,0 @@ -getSetting($mysqli,"name")); -define("TITLE", $db->getSetting($mysqli,"title")); -define("WEB_URL", $db->getSetting($mysqli,"url")); -define("MAILER_NAME", $db->getSetting($mysqli,"mailer")); -define("MAILER_ADDRESS", $db->getSetting($mysqli,"mailer_email")); -define("GOOGLE_RECAPTCHA", $db->getBooleanSetting($mysqli, "google_recaptcha")); -//define("", $db->getSettings($mysqli, "")); -define("GOOGLE_RECAPTCHA_SECRET", $db->getSetting($mysqli, "google_recaptcha_secret")); -define("GOOGLE_RECAPTCHA_SITEKEY", $db->getSetting($mysqli, "google_recaptcha_sitekey")); -define("SUBSCRIBE_EMAIL", $db->getBooleanSetting($mysqli, "subscribe_email")); -define("SUBSCRIBE_TELEGRAM", $db->getBooleanSetting($mysqli, "subscribe_telegram")); -define("TG_BOT_USERNAME", $db->getSetting($mysqli, "tg_bot_username")); -define("TG_BOT_API_TOKEN", $db->getSetting($mysqli, "tg_bot_api_token")); -define("PHP_MAILER", $db->getBooleanSetting($mysqli, "php_mailer")); -define("PHP_MAILER_SMTP", $db->getBooleanSetting($mysqli, "php_mailer_smtp")); -define("PHP_MAILER_PATH", $db->getSetting($mysqli, "php_mailer_path")); -define("PHP_MAILER_HOST", $db->getSetting($mysqli, "php_mailer_host")); -define("PHP_MAILER_PORT", $db->getSetting($mysqli, "php_mailer_port")); -define("PHP_MAILER_SECURE", $db->getBooleanSetting($mysqli, "php_mailer_secure")); -define("PHP_MAILER_USER", $db->getSetting($mysqli, "php_mailer_user")); -define("PHP_MAILER_PASS", $db->getSetting($mysqli, "php_mailer_pass")); - -$mailer = new Mailer(); -$subscriber = new Subscriber(); -$subscription = new Subscriptions(); - - -$boolRegistered = false; - -if ( isset($_GET['new']) ) { - - // Form validation for subscribers signing up - $message = ""; - Template :: render_header(_("Email Subscription")); - - if (isset($_POST['emailaddress'])) { - - if (0 == strlen(trim($_POST['emailaddress']))){ - $messages[] = _("Email address"); - } - - // Perform DNS domain validation on - if ( ! $mailer->verify_domain($_POST['emailaddress']) ) { - $messages[] = _("Domain does not apper to be a valid email domain. (Check MX record)"); - } - - if (GOOGLE_RECAPTCHA) { - // Validate recaptcha - $response = $_POST["g-recaptcha-response"]; - $url = 'https://www.google.com/recaptcha/api/siteverify'; - $data = array( - 'secret' => GOOGLE_RECAPTCHA_SECRET, - 'response' => $_POST["g-recaptcha-response"] - ); - $options = array( - 'http' => array ( - 'header' => 'Content-Type: application/x-www-form-urlencoded\r\n', - 'method' => 'POST', - 'content' => http_build_query($data) - ) - ); - $context = stream_context_create($options); - $verify = file_get_contents($url, false, $context); - $captcha_success = json_decode($verify); - - if ( $captcha_success->success==false ) { - $messages[] = _("reChaptcha validation failed"); - } - } - if ( isset($messages) ) { - $message = _("Please check
        "); - $message .= implode("
        ", $messages); - } - - } - - if(isset($_POST['emailaddress']) && empty($message)) - { - - // Check if email is already registered - $boolUserExist = false; - $subscriber->userID = $_POST['emailaddress']; - $subscriber->typeID = 2; // Email - $boolUserExist = $subscriber->check_userid_exist(); - - $url = WEB_URL."/index.php?do=manage&token=".$subscriber->token; - - if ( ! $boolUserExist ) { - // Create a new subscriber as it does not exist - $subscriber->add($subscriber->typeID, $_POST['emailaddress']); - $url = WEB_URL."/index.php?do=manage&token=".$subscriber->token; // Needed again after adding subscriber since token did not exist before add - $msg = sprintf(_("Thank you for registering to receive status updates via email.

        Click on the following link to confirm and manage your subcription: %s. New subscriptions must be confirmed within 2 hours"), $url, NAME .' - ' . _("Validate subscription")); - - } else { - if ( ! $subscriber->active ) { - // Subscriber is registered, but has not been activated yet... - $msg = sprintf(_("Thank you for registering to receive status updates via email.

        Click on the following link to confirm and manage your subcription: %s. New subscriptions must be confirmed within 2 hours"), $url, NAME .' - ' . _("Validate subscription")); - $subscriber->activate($subscriber->id); - - } else { - // subscriber is registered and active - $msg = sprintf(_("Click on the following link to update your existing subscription: %s"), $url, NAME .' - ' . _("Manage subscription")); - $subscriber->update($subscriber->id); - } - } - // Show success message - $header = _("Thank you for subscribing"); - $message = _("You will receive an email shortly with an activation link. Please click on the link to activate and/or manage your subscription."); - $constellation->render_success($header, $message, true, WEB_URL, _('Go back')); - - // Send email about new registration - $subject = _('Email subscription registered').' - '.NAME; - $mailer->send_mail($_POST['emailaddress'], $subject, $msg); - - $boolRegistered = true; - } - - // Add a new email subscriber - display form - if ( isset($_GET['new']) && (! $boolRegistered) ) { - - if (!empty($message)) { - echo '

        '.$message.'

        '; - } - $strPostedEmail = (isset($_POST['emailaddress'])) ? $_POST['emailaddress'] : ""; - ?> - - -
        -

        -
        - - -
        - -
        -
        -
        -
        -
        -
        -
        - - - Privacy Policy'), POLICY_URL); - echo $msg; - ?> - -
        -
        - - -
        - typeID = 2; //EMAIL - if ( $subscriber->is_active_subscriber($_GET['token']) ) { - // forward user to subscriber list.... - $subscriber->set_logged_in(); - header('Location: subscriptions.php'); - exit; - } else { - Template :: render_header(_("Email Subscription")); - - $header = _("We cannot find a valid subscriber account matching those details"); - $message = _("If you have recently subscribed, please make sure you activate the account within two hours of doing so. You are welcome to try and re-subscribe."); - $constellation->render_warning($header, $message, true, WEB_URL, _('Go back')); - } - - -} else if (isset($_GET['do']) && $_GET['do'] == 'unsubscribe') { - // Handle unsubscriptions - // TODO This function is universal and should probably live elsewhere?? - if (isset($_GET['token'])) { - $subscriber->typeID = (int) $_GET['type']; - - if ( $subscriber->get_subscriber_by_token($_GET['token'])) { - $subscriber->delete($subscriber->id); - $subscriber->set_logged_off(); - Template :: render_header(_("Email Subscription")); - - $header = _("You have been unsubscribed from our system"); - $message = _("We are sorry to see you go. If you want to subscribe again at a later date please feel free to re-subscribe."); - $constellation->render_success($header, $message, true, WEB_URL, _('Go back')); - - } else { - // TODO Log token for troubleshooting ? - // Cannot find subscriber - show alert - Template :: render_header(_("Email Subscription")); - $header = _("We are unable to find any valid subscriber detail matching your submitted data!"); - $message = _("If you believe this to be an error, please contact the system admininistrator."); - $constellation->render_warning($header, $message, true, WEB_URL, _('Go back')); - - // - } - } else { - // TODO Log $_GET[] for troubleshooting ? - $header = _("We are unable to find any valid subscriber detail matching your submitted data!"); - $message = _("If you believe this to be an error, please contact the system admininistrator."); - $constellation->render_warning($header, $message, true, WEB_URL, _('Go back')); - } -} -Template :: render_footer(); diff --git a/fonts/glyphicons-halflings-regular.eot b/fonts/glyphicons-halflings-regular.eot deleted file mode 100644 index b93a495..0000000 Binary files a/fonts/glyphicons-halflings-regular.eot and /dev/null differ diff --git a/fonts/glyphicons-halflings-regular.svg b/fonts/glyphicons-halflings-regular.svg deleted file mode 100644 index 94fb549..0000000 --- a/fonts/glyphicons-halflings-regular.svg +++ /dev/null @@ -1,288 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/fonts/glyphicons-halflings-regular.ttf b/fonts/glyphicons-halflings-regular.ttf deleted file mode 100644 index 1413fc6..0000000 Binary files a/fonts/glyphicons-halflings-regular.ttf and /dev/null differ diff --git a/fonts/glyphicons-halflings-regular.woff b/fonts/glyphicons-halflings-regular.woff deleted file mode 100644 index 9e61285..0000000 Binary files a/fonts/glyphicons-halflings-regular.woff and /dev/null differ diff --git a/fonts/glyphicons-halflings-regular.woff2 b/fonts/glyphicons-halflings-regular.woff2 deleted file mode 100644 index 64539b5..0000000 Binary files a/fonts/glyphicons-halflings-regular.woff2 and /dev/null differ diff --git a/index.php b/index.php deleted file mode 100644 index c05380e..0000000 --- a/index.php +++ /dev/null @@ -1,121 +0,0 @@ -getSetting($mysqli,"name")); -define("TITLE", $db->getSetting($mysqli,"title")); -define("WEB_URL", $db->getSetting($mysqli,"url")); -define("MAILER_NAME", $db->getSetting($mysqli,"mailer")); -define("MAILER_ADDRESS", $db->getSetting($mysqli,"mailer_email")); - -define("SUBSCRIBE_EMAIL", $db->getBooleanSetting($mysqli,"subscribe_email")); -define("SUBSCRIBE_TELEGRAM", $db->getBooleanSetting($mysqli,"subscribe_telegram")); -define("TG_BOT_USERNAME", $db->getSetting($mysqli,"tg_bot_username")); -define("TG_BOT_API_TOKEN", $db->getSetting($mysqli,"tg_bot_api_token")); -define("GOOGLE_RECAPTCHA", $db->getBooleanSetting($mysqli,"google_recaptcha")); -define("GOOGLE_RECAPTCHA_SITEKEY", $db->getSetting($mysqli,"google_recaptcha_sitekey")); -define("GOOGLE_RECAPTCHA_SECRET", $db->getSetting($mysqli,"google_recaptcha_secret")); -$offset = 0; - -if (isset($_GET['ajax'])) -{ - $constellation->render_incidents(false,$_GET['offset'],5); - exit(); -}else if (isset($_GET['offset'])) -{ - $offset = $_GET['offset']; -} - -if (isset($_GET['subscriber_logout'])){ - setcookie('tg_user', ''); - setcookie('referer', '', time() - 3600); - $_SESSION['subscriber_valid'] = false; - unset($_SESSION['subscriber_userid']); - unset($_SESSION['subscriber_typeid']); - unset($_SESSION['subscriber_id']); - header('Location: index.php'); -} -/* -$versionfile = fopen("versionfile", "r") or die("Unable to open version file!"); -$appversion = fread($versionfile,filesize("versionfile")); -fclose($versionfile); -if($db->getSetting($mysqli,"dbConfigVersion") != trim($appversion)){ - die("Database needs to be updated. Please update the database and try again. App Version: '".$appversion."' DB Settings Version: '".$db->getSetting($mysqli,"dbConfigVersion")."'."); -} -$useedf = fopen("updateseed", "r") or die("Unable to open updateseed file!"); -$useed = fread($useedf,filesize("updateseed")); -fclose($useedf); -if(trim($useed) == "stable"){ -$remoteversion = file_get_contents("https://skyfallenhosted.ml/serverstatus/versionauthority/stable/version"); -$remotedl = file_get_contents("https://skyfallenhosted.ml/serverstatus/versionauthority/stable/dl"); -} -if(trim($useed) == "beta"){ -$remoteversion = file_get_contents("https://skyfallenhosted.ml/serverstatus/versionauthority/beta/version"); -$remotedl = file_get_contents("https://skyfallenhosted.ml/serverstatus/versionauthority/beta/dl"); -} -if($db->getSetting($mysqli,"notifyUpdates") == "yes"){ - if(trim($remoteversion) != trim($appversion)){ - die("Your installation is not upp to date! Download the new update from: '".$remotedl."' Your version is:'".$appversion."' Remote Authority Version is:'".$remoteversion."' Your Update Seed is:'".$useed."' Remote Package Authority is Skyfallen.
        If you cannot access Remote Authority, please check status.theskyfallen.com and skyfallenhosted.ml manually."); - } -} -*/ -Template::render_header("Status"); -?> -
        -

        -
        -
        - render_status();?> -
        - -query("SELECT count(*) FROM status")->num_rows) -{ - ?> -
        -
        -
        -
        - render_incidents(true,$offset); - $constellation->render_incidents(false,$offset); - ?> -
        -
        -
        -negotiate($override); - $_SESSION['locale'] = $best_match; - setlocale(LC_ALL, $_SESSION['locale'].".UTF-8"); - - bindtextdomain("server-status", __DIR__ . "/locale/"); - bind_textdomain_codeset($_SESSION['locale'], "utf-8"); - textdomain("server-status"); -} - -if (isset($_POST['server'])) -{ - $mysqli = new mysqli($_POST['server'],$_POST['dbuser'],$_POST['dbpassword'],$_POST['database']); - - if ($mysqli->connect_errno) { - $message .= sprintf(_("Connection failed: %s\n"), $mysqli->connect_error); - } - - if (isset($_POST['url']) && filter_var($_POST['url'], FILTER_VALIDATE_URL) === false) - { - $message .= _("Please set valid url!"); - } - - //Ostatní má checky existence ve funkci pro pridani - if (0 == strlen(trim($_POST['servername']))){ - $messages[] = _("Server name"); - } - - if (0 == strlen(trim($_POST['url']))){ - $messages[] = _("Url"); - } - - if (0 == strlen(trim($_POST['mailer']))){ - $messages[] = _("Mailer name"); - } - - if (0 == strlen(trim($_POST['title']))){ - $messages[] = _("Title"); - } - - if (0 == strlen(trim($_POST['mailer_email']))){ - $messages[] = _("Mailer email"); - } - - if (0 == strlen(trim($_POST['server']))){ - $messages[] = _("Database server"); - } - - if (0 == strlen(trim($_POST['database']))){ - $messages[] = _("Database name"); - } - - if (0 == strlen(trim($_POST['dbuser']))){ - $messages[] = _("Database user"); - } - - if (0 == strlen(trim($_POST['dbpassword']))) - { - $messages[] = _("Database password"); - } - if (isset($messages)) - { - $message .= _("Please enter"); - $message .= implode(", ", $messages); - } -} - -if(isset($_POST['server']) && empty($message)) -{ - define("MAILER_NAME", $_POST['mailer']); - define("MAILER_ADDRESS", $_POST['mailer_email']); - define("INSTALL_OVERRIDE", true); - - //No need to include config, as we have connection from testing it... :) - //There may be better way to do this... - $sql = file_get_contents("install.sql"); - $array = explode(";", $sql); - - foreach ($array as $value) { - $val = trim($value); - if (empty($val)) - { - continue; - } - $q_res = $mysqli->query($value); - if ($q_res === false) - { - $message = sprintf(_("Error while creating database. Please check permission for your account or MYSQL version.
        Error: %s"), $mysqli->error); - break; - } - } - - if (empty($message)) - { - require_once("classes/constellation.php"); - - User::add(); - } - - if (empty($message)) - { - //Create config - $config = file_get_contents("config.php.template"); - //$config = str_replace("##name##", htmlspecialchars($_POST['servername'], ENT_QUOTES), $config); - $db->setSetting($mysqli,"name",htmlspecialchars($_POST['servername'], ENT_QUOTES)); - //$config = str_replace("##title##", htmlspecialchars($_POST['title'], ENT_QUOTES), $config); - $db->setSetting($mysqli,"title",htmlspecialchars($_POST['title'], ENT_QUOTES)); - //$config = str_replace("##url##", $_POST['url'], $config); - $db->setSetting($mysqli,"url",$_POST['url']); - //$config = str_replace("##mailer##", htmlspecialchars($_POST['mailer'], ENT_QUOTES), $config); - $db->setSetting($mysqli,"mailer",htmlspecialchars($_POST['mailer'], ENT_QUOTES)); - //$config = str_replace("##mailer_email##", htmlspecialchars($_POST['mailer_email'], ENT_QUOTES), $config); - $db->setSetting($mysqli,"mailer_email",htmlspecialchars($_POST['mailer_email'], ENT_QUOTES)); - $config = str_replace("##server##", htmlspecialchars($_POST['server'], ENT_QUOTES), $config); - $config = str_replace("##database##", htmlspecialchars($_POST['database'], ENT_QUOTES), $config); - $config = str_replace("##user##", htmlspecialchars($_POST['dbuser'], ENT_QUOTES), $config); - $config = str_replace("##password##", htmlspecialchars($_POST['dbpassword'], ENT_QUOTES), $config); - // Duplicate of lines 122-123 //$config = str_replace("##name##", htmlspecialchars($_POST['servername'], ENT_QUOTES), $config); - $config = str_replace("##policy_name##", htmlspecialchars($_POST['policy_name'], ENT_QUOTES), $config); - $config = str_replace("##address##", htmlspecialchars($_POST['address'], ENT_QUOTES), $config); - $config = str_replace("##policy_mail##", htmlspecialchars($_POST['policy_mail'], ENT_QUOTES), $config); - $config = str_replace("##policy_phone##", htmlspecialchars($_POST['policy_phone'], ENT_QUOTES),$config); - $config = str_replace("##who_we_are##", htmlspecialchars($_POST['who_we_are'], ENT_QUOTES), $config); - $policy_url_conf = ( ! empty($_POST['policy_url']) ) ? htmlspecialchars($_POST['policy_url'], ENT_QUOTES) : $_POST['url']."/policy.php"; - $config = str_replace("##policy_url##", $policy_url_conf, $config); - - file_put_contents("config.php", $config); - - include_once "create-server-config.php"; - $db->setSetting($mysqli,"dbConfigVersion","Version2Beta7"); - $db->setSetting($mysqli,"notifyUpdates","yes"); - $db->setSetting($mysqli,"subscribe_email","no"); - $db->setSetting($mysqli,"subscribe_telegram","no"); - $db->setSetting($mysqli,"tg_bot_api_token",""); - $db->setSetting($mysqli,"tg_bot_username",""); - $db->setSetting($mysqli,"php_mailer","no"); - $db->setSetting($mysqli,"php_mailer_host",""); - $db->setSetting($mysqli,"php_mailer_smtp","no"); - $db->setSetting($mysqli,"php_mailer_path",""); - $db->setSetting($mysqli,"php_mailer_port",""); - $db->setSetting($mysqli,"php_mailer_secure","no"); - $db->setSetting($mysqli,"php_mailer_user",""); - $db->setSetting($mysqli,"php_mailer_pass",""); - $db->setSetting($mysqli,"google_recaptcha","no"); - $db->setSetting($mysqli,"google_recaptcha_secret",""); - $db->setSetting($mysqli,"google_recaptcha_sitekey",""); - $db->setSetting($mysqli,"cron_server_ip",""); - if(!$isDeveleoperEnvironement) { - unlink("create-server-config.php"); - unlink("config.php.template"); - unlink("install.sql"); - unlink(__FILE__); - } - header("Location: ".WEB_URL); - } -} -Template::render_header(_("Install")); -?> -

        - - MINIMUM_PHP_VERSION - if (strnatcmp(phpversion(), MINIMUM_PHP_VERSION) >= 0) { $preq_phpver = $preq_ok; } - - // Test for mysqlnd precense. The mysqlnd driver provides some extra functions that is not available - // if the plain mysql package is installed, and mysqli_get_client_stats is one of them. This is documented - // on the PHP site at http://www.php.net/manual/en/mysqlnd.stats.php - // This test is also discussed at https://stackoverflow.com/questions/1475701/how-to-know-if-mysqlnd-is-the-active-driver - if ( function_exists('mysqli_get_client_stats') ) { $preq_mysqlnd = $preq_ok; } - - // Check if we have access to write to location - if ( is_writable(__DIR__) ) { $preq_writedir = $preq_ok; } - -?> -
        -
        -
        -
        -
        -
        -
        -
        -
        -
        -
        -
        -
        -
        -
        - -
        - -

        - -

        - - - -
        -
        -

        - https://example.com/status - without the trailing slash), so we can mail users link for forgotten password etc...");?> - -
        -
        " class="form-control" required>
        -
        " class="form-control" required>
        -
        - -
        -
        " class="form-control" required>
        -
        -
        - -
        -
        " class="form-control" required>
        -
        " class="form-control" required>
        -
        -
        -
        -

        - - -
        -
        " class="form-control" required>
        -
        " class="form-control" required>
        -
        -
        -
        " class="form-control" required>
        -
        " class="form-control" required>
        -
        -
        -
        -

        - - -
        -
        " class="form-control" required>
        -
        " class="form-control" required>
        -
        -
        -
        " class="form-control" required>
        -
        " class="form-control">
        -
        -
        -
        -
        -
        -
        - - " class="form-control"> -
        -
        -
        -
        -

        - -
        -
        " class="form-control" required>
        -
        " class="form-control" required>
        -
        -
        -
        " class="form-control" required>
        -
        " class="form-control" required>
        -
        -
        -
        " class="form-control" required>
        -
        - - -
        -
        -
        -
        -= end_time) - { - $.growl.error({ message: "End time is either the same or earlier than start time!" }); - $("#time").addClass("error"); - $("#end_time").addClass("error"); - return false; - } - - if($("#status-container :checkbox:checked").length === 0) - { - $.growl.error({ message: "Please check at least one service!" }); - $("#status-container").addClass("error"); - return false; - } - }); -})(); - diff --git a/js/main.js b/js/main.js deleted file mode 100644 index 063b261..0000000 --- a/js/main.js +++ /dev/null @@ -1,32 +0,0 @@ -function timeago() -{ - $("time.timeago").timeago(); - $("time.timeago").each(function(){ - var date = new Date($(this).attr("datetime")); - $(this).attr("title",date.toLocaleString()); - }); -} - -(function(){ - jQuery.timeago.settings.allowFuture = true; - - timeago(); - - $("body").on("click", ".navbar-toggle", function(){ - $($(this).data("target")).toggleClass("collapse"); - }); - - var incidents = $('.timeline'); - $("body").on("click", "#loadmore", function(e){ - e.preventDefault(); - var url = $("#loadmore").attr("href") + "&ajax=true"; - $("#loadmore").remove(); - - $.get(url, - function(data){ - incidents.append(data); - timeago(); - }); - }); - })(); - diff --git a/js/vendor/bootstrap.min.js b/js/vendor/bootstrap.min.js deleted file mode 100644 index eb0a8b4..0000000 --- a/js/vendor/bootstrap.min.js +++ /dev/null @@ -1,6 +0,0 @@ -/*! - * Bootstrap v3.4.1 (https://getbootstrap.com/) - * Copyright 2011-2019 Twitter, Inc. - * Licensed under the MIT license - */ -if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");!function(t){"use strict";var e=jQuery.fn.jquery.split(" ")[0].split(".");if(e[0]<2&&e[1]<9||1==e[0]&&9==e[1]&&e[2]<1||3this.$items.length-1||t<0))return this.sliding?this.$element.one("slid.bs.carousel",function(){e.to(t)}):i==t?this.pause().cycle():this.slide(idocument.documentElement.clientHeight;this.$element.css({paddingLeft:!this.bodyIsOverflowing&&t?this.scrollbarWidth:"",paddingRight:this.bodyIsOverflowing&&!t?this.scrollbarWidth:""})},s.prototype.resetAdjustments=function(){this.$element.css({paddingLeft:"",paddingRight:""})},s.prototype.checkScrollbar=function(){var t=window.innerWidth;if(!t){var e=document.documentElement.getBoundingClientRect();t=e.right-Math.abs(e.left)}this.bodyIsOverflowing=document.body.clientWidth
        ',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0},sanitize:!0,sanitizeFn:null,whiteList:t},m.prototype.init=function(t,e,i){if(this.enabled=!0,this.type=t,this.$element=g(e),this.options=this.getOptions(i),this.$viewport=this.options.viewport&&g(document).find(g.isFunction(this.options.viewport)?this.options.viewport.call(this,this.$element):this.options.viewport.selector||this.options.viewport),this.inState={click:!1,hover:!1,focus:!1},this.$element[0]instanceof document.constructor&&!this.options.selector)throw new Error("`selector` option must be specified when initializing "+this.type+" on the window.document object!");for(var o=this.options.trigger.split(" "),n=o.length;n--;){var s=o[n];if("click"==s)this.$element.on("click."+this.type,this.options.selector,g.proxy(this.toggle,this));else if("manual"!=s){var a="hover"==s?"mouseenter":"focusin",r="hover"==s?"mouseleave":"focusout";this.$element.on(a+"."+this.type,this.options.selector,g.proxy(this.enter,this)),this.$element.on(r+"."+this.type,this.options.selector,g.proxy(this.leave,this))}}this.options.selector?this._options=g.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},m.prototype.getDefaults=function(){return m.DEFAULTS},m.prototype.getOptions=function(t){var e=this.$element.data();for(var i in e)e.hasOwnProperty(i)&&-1!==g.inArray(i,o)&&delete e[i];return(t=g.extend({},this.getDefaults(),e,t)).delay&&"number"==typeof t.delay&&(t.delay={show:t.delay,hide:t.delay}),t.sanitize&&(t.template=n(t.template,t.whiteList,t.sanitizeFn)),t},m.prototype.getDelegateOptions=function(){var i={},o=this.getDefaults();return this._options&&g.each(this._options,function(t,e){o[t]!=e&&(i[t]=e)}),i},m.prototype.enter=function(t){var e=t instanceof this.constructor?t:g(t.currentTarget).data("bs."+this.type);if(e||(e=new this.constructor(t.currentTarget,this.getDelegateOptions()),g(t.currentTarget).data("bs."+this.type,e)),t instanceof g.Event&&(e.inState["focusin"==t.type?"focus":"hover"]=!0),e.tip().hasClass("in")||"in"==e.hoverState)e.hoverState="in";else{if(clearTimeout(e.timeout),e.hoverState="in",!e.options.delay||!e.options.delay.show)return e.show();e.timeout=setTimeout(function(){"in"==e.hoverState&&e.show()},e.options.delay.show)}},m.prototype.isInStateTrue=function(){for(var t in this.inState)if(this.inState[t])return!0;return!1},m.prototype.leave=function(t){var e=t instanceof this.constructor?t:g(t.currentTarget).data("bs."+this.type);if(e||(e=new this.constructor(t.currentTarget,this.getDelegateOptions()),g(t.currentTarget).data("bs."+this.type,e)),t instanceof g.Event&&(e.inState["focusout"==t.type?"focus":"hover"]=!1),!e.isInStateTrue()){if(clearTimeout(e.timeout),e.hoverState="out",!e.options.delay||!e.options.delay.hide)return e.hide();e.timeout=setTimeout(function(){"out"==e.hoverState&&e.hide()},e.options.delay.hide)}},m.prototype.show=function(){var t=g.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){this.$element.trigger(t);var e=g.contains(this.$element[0].ownerDocument.documentElement,this.$element[0]);if(t.isDefaultPrevented()||!e)return;var i=this,o=this.tip(),n=this.getUID(this.type);this.setContent(),o.attr("id",n),this.$element.attr("aria-describedby",n),this.options.animation&&o.addClass("fade");var s="function"==typeof this.options.placement?this.options.placement.call(this,o[0],this.$element[0]):this.options.placement,a=/\s?auto?\s?/i,r=a.test(s);r&&(s=s.replace(a,"")||"top"),o.detach().css({top:0,left:0,display:"block"}).addClass(s).data("bs."+this.type,this),this.options.container?o.appendTo(g(document).find(this.options.container)):o.insertAfter(this.$element),this.$element.trigger("inserted.bs."+this.type);var l=this.getPosition(),h=o[0].offsetWidth,d=o[0].offsetHeight;if(r){var p=s,c=this.getPosition(this.$viewport);s="bottom"==s&&l.bottom+d>c.bottom?"top":"top"==s&&l.top-dc.width?"left":"left"==s&&l.left-ha.top+a.height&&(n.top=a.top+a.height-l)}else{var h=e.left-s,d=e.left+s+i;ha.right&&(n.left=a.left+a.width-d)}return n},m.prototype.getTitle=function(){var t=this.$element,e=this.options;return t.attr("data-original-title")||("function"==typeof e.title?e.title.call(t[0]):e.title)},m.prototype.getUID=function(t){for(;t+=~~(1e6*Math.random()),document.getElementById(t););return t},m.prototype.tip=function(){if(!this.$tip&&(this.$tip=g(this.options.template),1!=this.$tip.length))throw new Error(this.type+" `template` option must consist of exactly 1 top-level element!");return this.$tip},m.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},m.prototype.enable=function(){this.enabled=!0},m.prototype.disable=function(){this.enabled=!1},m.prototype.toggleEnabled=function(){this.enabled=!this.enabled},m.prototype.toggle=function(t){var e=this;t&&((e=g(t.currentTarget).data("bs."+this.type))||(e=new this.constructor(t.currentTarget,this.getDelegateOptions()),g(t.currentTarget).data("bs."+this.type,e))),t?(e.inState.click=!e.inState.click,e.isInStateTrue()?e.enter(e):e.leave(e)):e.tip().hasClass("in")?e.leave(e):e.enter(e)},m.prototype.destroy=function(){var t=this;clearTimeout(this.timeout),this.hide(function(){t.$element.off("."+t.type).removeData("bs."+t.type),t.$tip&&t.$tip.detach(),t.$tip=null,t.$arrow=null,t.$viewport=null,t.$element=null})},m.prototype.sanitizeHtml=function(t){return n(t,this.options.whiteList,this.options.sanitizeFn)};var e=g.fn.tooltip;g.fn.tooltip=function i(o){return this.each(function(){var t=g(this),e=t.data("bs.tooltip"),i="object"==typeof o&&o;!e&&/destroy|hide/.test(o)||(e||t.data("bs.tooltip",e=new m(this,i)),"string"==typeof o&&e[o]())})},g.fn.tooltip.Constructor=m,g.fn.tooltip.noConflict=function(){return g.fn.tooltip=e,this}}(jQuery),function(n){"use strict";var s=function(t,e){this.init("popover",t,e)};if(!n.fn.tooltip)throw new Error("Popover requires tooltip.js");s.VERSION="3.4.1",s.DEFAULTS=n.extend({},n.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:''}),((s.prototype=n.extend({},n.fn.tooltip.Constructor.prototype)).constructor=s).prototype.getDefaults=function(){return s.DEFAULTS},s.prototype.setContent=function(){var t=this.tip(),e=this.getTitle(),i=this.getContent();if(this.options.html){var o=typeof i;this.options.sanitize&&(e=this.sanitizeHtml(e),"string"===o&&(i=this.sanitizeHtml(i))),t.find(".popover-title").html(e),t.find(".popover-content").children().detach().end()["string"===o?"html":"append"](i)}else t.find(".popover-title").text(e),t.find(".popover-content").children().detach().end().text(i);t.removeClass("fade top bottom left right in"),t.find(".popover-title").html()||t.find(".popover-title").hide()},s.prototype.hasContent=function(){return this.getTitle()||this.getContent()},s.prototype.getContent=function(){var t=this.$element,e=this.options;return t.attr("data-content")||("function"==typeof e.content?e.content.call(t[0]):e.content)},s.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")};var t=n.fn.popover;n.fn.popover=function e(o){return this.each(function(){var t=n(this),e=t.data("bs.popover"),i="object"==typeof o&&o;!e&&/destroy|hide/.test(o)||(e||t.data("bs.popover",e=new s(this,i)),"string"==typeof o&&e[o]())})},n.fn.popover.Constructor=s,n.fn.popover.noConflict=function(){return n.fn.popover=t,this}}(jQuery),function(s){"use strict";function n(t,e){this.$body=s(document.body),this.$scrollElement=s(t).is(document.body)?s(window):s(t),this.options=s.extend({},n.DEFAULTS,e),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",s.proxy(this.process,this)),this.refresh(),this.process()}function e(o){return this.each(function(){var t=s(this),e=t.data("bs.scrollspy"),i="object"==typeof o&&o;e||t.data("bs.scrollspy",e=new n(this,i)),"string"==typeof o&&e[o]()})}n.VERSION="3.4.1",n.DEFAULTS={offset:10},n.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},n.prototype.refresh=function(){var t=this,o="offset",n=0;this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight(),s.isWindow(this.$scrollElement[0])||(o="position",n=this.$scrollElement.scrollTop()),this.$body.find(this.selector).map(function(){var t=s(this),e=t.data("target")||t.attr("href"),i=/^#./.test(e)&&s(e);return i&&i.length&&i.is(":visible")&&[[i[o]().top+n,e]]||null}).sort(function(t,e){return t[0]-e[0]}).each(function(){t.offsets.push(this[0]),t.targets.push(this[1])})},n.prototype.process=function(){var t,e=this.$scrollElement.scrollTop()+this.options.offset,i=this.getScrollHeight(),o=this.options.offset+i-this.$scrollElement.height(),n=this.offsets,s=this.targets,a=this.activeTarget;if(this.scrollHeight!=i&&this.refresh(),o<=e)return a!=(t=s[s.length-1])&&this.activate(t);if(a&&e=n[t]&&(n[t+1]===undefined||e .active"),n=i&&r.support.transition&&(o.length&&o.hasClass("fade")||!!e.find("> .fade").length);function s(){o.removeClass("active").find("> .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!1),t.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded",!0),n?(t[0].offsetWidth,t.addClass("in")):t.removeClass("fade"),t.parent(".dropdown-menu").length&&t.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!0),i&&i()}o.length&&n?o.one("bsTransitionEnd",s).emulateTransitionEnd(a.TRANSITION_DURATION):s(),o.removeClass("in")};var t=r.fn.tab;r.fn.tab=e,r.fn.tab.Constructor=a,r.fn.tab.noConflict=function(){return r.fn.tab=t,this};var i=function(t){t.preventDefault(),e.call(r(this),"show")};r(document).on("click.bs.tab.data-api",'[data-toggle="tab"]',i).on("click.bs.tab.data-api",'[data-toggle="pill"]',i)}(jQuery),function(l){"use strict";var h=function(t,e){this.options=l.extend({},h.DEFAULTS,e);var i=this.options.target===h.DEFAULTS.target?l(this.options.target):l(document).find(this.options.target);this.$target=i.on("scroll.bs.affix.data-api",l.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",l.proxy(this.checkPositionWithEventLoop,this)),this.$element=l(t),this.affixed=null,this.unpin=null,this.pinnedOffset=null,this.checkPosition()};function i(o){return this.each(function(){var t=l(this),e=t.data("bs.affix"),i="object"==typeof o&&o;e||t.data("bs.affix",e=new h(this,i)),"string"==typeof o&&e[o]()})}h.VERSION="3.4.1",h.RESET="affix affix-top affix-bottom",h.DEFAULTS={offset:0,target:window},h.prototype.getState=function(t,e,i,o){var n=this.$target.scrollTop(),s=this.$element.offset(),a=this.$target.height();if(null!=i&&"top"==this.affixed)return n 0 && arguments[0] !== undefined ? arguments[0] : {}; - - return new Growl(settings); - } - }]); - - function Growl() { - var settings = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; - - _classCallCheck(this, Growl); - - this.render = this.render.bind(this); - this.bind = this.bind.bind(this); - this.unbind = this.unbind.bind(this); - this.mouseEnter = this.mouseEnter.bind(this); - this.mouseLeave = this.mouseLeave.bind(this); - this.click = this.click.bind(this); - this.close = this.close.bind(this); - this.cycle = this.cycle.bind(this); - this.waitAndDismiss = this.waitAndDismiss.bind(this); - this.present = this.present.bind(this); - this.dismiss = this.dismiss.bind(this); - this.remove = this.remove.bind(this); - this.animate = this.animate.bind(this); - this.$growls = this.$growls.bind(this); - this.$growl = this.$growl.bind(this); - this.html = this.html.bind(this); - this.content = this.content.bind(this); - this.container = this.container.bind(this); - this.settings = $.extend({}, Growl.settings, settings); - this.initialize(this.settings.location); - this.render(); - } - - _createClass(Growl, [{ - key: "initialize", - value: function initialize(location) { - var id; - id = 'growls-' + location; - return $('body:not(:has(#' + id + '))').append('
        '); - } - }, { - key: "render", - value: function render() { - var $growl; - $growl = this.$growl(); - this.$growls(this.settings.location).append($growl); - if (this.settings.fixed) { - this.present(); - } else { - this.cycle(); - } - } - }, { - key: "bind", - value: function bind() { - var $growl = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.$growl(); - - $growl.on("click", this.click); - if (this.settings.delayOnHover) { - $growl.on("mouseenter", this.mouseEnter); - $growl.on("mouseleave", this.mouseLeave); - } - return $growl.on("contextmenu", this.close).find("." + this.settings.namespace + "-close").on("click", this.close); - } - }, { - key: "unbind", - value: function unbind() { - var $growl = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.$growl(); - - $growl.off("click", this.click); - if (this.settings.delayOnHover) { - $growl.off("mouseenter", this.mouseEnter); - $growl.off("mouseleave", this.mouseLeave); - } - return $growl.off("contextmenu", this.close).find("." + this.settings.namespace + "-close").off("click", this.close); - } - }, { - key: "mouseEnter", - value: function mouseEnter(event) { - var $growl; - $growl = this.$growl(); - return $growl.stop(true, true); - } - }, { - key: "mouseLeave", - value: function mouseLeave(event) { - return this.waitAndDismiss(); - } - }, { - key: "click", - value: function click(event) { - if (this.settings.url != null) { - event.preventDefault(); - event.stopPropagation(); - return window.open(this.settings.url); - } - } - }, { - key: "close", - value: function close(event) { - var $growl; - event.preventDefault(); - event.stopPropagation(); - $growl = this.$growl(); - return $growl.stop().queue(this.dismiss).queue(this.remove); - } - }, { - key: "cycle", - value: function cycle() { - var $growl; - $growl = this.$growl(); - return $growl.queue(this.present).queue(this.waitAndDismiss()); - } - }, { - key: "waitAndDismiss", - value: function waitAndDismiss() { - var $growl; - $growl = this.$growl(); - return $growl.delay(this.settings.duration).queue(this.dismiss).queue(this.remove); - } - }, { - key: "present", - value: function present(callback) { - var $growl; - $growl = this.$growl(); - this.bind($growl); - return this.animate($growl, this.settings.namespace + "-incoming", 'out', callback); - } - }, { - key: "dismiss", - value: function dismiss(callback) { - var $growl; - $growl = this.$growl(); - this.unbind($growl); - return this.animate($growl, this.settings.namespace + "-outgoing", 'in', callback); - } - }, { - key: "remove", - value: function remove(callback) { - this.$growl().remove(); - return typeof callback === "function" ? callback() : void 0; - } - }, { - key: "animate", - value: function animate($element, name) { - var direction = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'in'; - var callback = arguments[3]; - - var transition; - transition = Animation.transition($element); - $element[direction === 'in' ? 'removeClass' : 'addClass'](name); - $element.offset().position; - $element[direction === 'in' ? 'addClass' : 'removeClass'](name); - if (callback == null) { - return; - } - if (transition != null) { - $element.one(transition, callback); - } else { - callback(); - } - } - }, { - key: "$growls", - value: function $growls(location) { - var base; - if (this.$_growls == null) { - this.$_growls = []; - } - return (base = this.$_growls)[location] != null ? base[location] : base[location] = $('#growls-' + location); - } - }, { - key: "$growl", - value: function $growl() { - return this.$_growl != null ? this.$_growl : this.$_growl = $(this.html()); - } - }, { - key: "html", - value: function html() { - return this.container(this.content()); - } - }, { - key: "content", - value: function content() { - return "
        " + this.settings.close + "
        \n
        " + this.settings.title + "
        \n
        " + this.settings.message + "
        "; - } - }, { - key: "container", - value: function container(content) { - return "
        \n " + content + "\n
        "; - } - }]); - - return Growl; - }(); - - ; - - Growl.settings = { - namespace: 'growl', - duration: 3200, - close: "×", - location: "default", - style: "default", - size: "medium", - delayOnHover: true - }; - - return Growl; - }(); - - this.Growl = Growl; - - $.growl = function () { - var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; - - return Growl.growl(options); - }; - - $.growl.error = function () { - var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; - - var settings; - settings = { - title: "Error!", - style: "error" - }; - return $.growl($.extend(settings, options)); - }; - - $.growl.notice = function () { - var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; - - var settings; - settings = { - title: "Notice!", - style: "notice" - }; - return $.growl($.extend(settings, options)); - }; - - $.growl.warning = function () { - var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; - - var settings; - settings = { - title: "Warning!", - style: "warning" - }; - return $.growl($.extend(settings, options)); - }; -}).call(this); \ No newline at end of file diff --git a/js/vendor/jquery.timeago.js b/js/vendor/jquery.timeago.js deleted file mode 100644 index ec80c32..0000000 --- a/js/vendor/jquery.timeago.js +++ /dev/null @@ -1,232 +0,0 @@ -/** - * Timeago is a jQuery plugin that makes it easy to support automatically - * updating fuzzy timestamps (e.g. "4 minutes ago" or "about 1 day ago"). - * - * @name timeago - * @version 1.6.7 - * @requires jQuery >=1.5.0 <4.0 - * @author Ryan McGeary - * @license MIT License - http://www.opensource.org/licenses/mit-license.php - * - * For usage and examples, visit: - * http://timeago.yarp.com/ - * - * Copyright (c) 2008-2019, Ryan McGeary (ryan -[at]- mcgeary [*dot*] org) - */ - -(function (factory) { - if (typeof define === 'function' && define.amd) { - // AMD. Register as an anonymous module. - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - // Browser globals - factory(jQuery); - } -}(function ($) { - $.timeago = function(timestamp) { - if (timestamp instanceof Date) { - return inWords(timestamp); - } else if (typeof timestamp === "string") { - return inWords($.timeago.parse(timestamp)); - } else if (typeof timestamp === "number") { - return inWords(new Date(timestamp)); - } else { - return inWords($.timeago.datetime(timestamp)); - } - }; - var $t = $.timeago; - - $.extend($.timeago, { - settings: { - refreshMillis: 60000, - allowPast: true, - allowFuture: false, - localeTitle: false, - cutoff: 0, - autoDispose: true, - strings: { - prefixAgo: null, - prefixFromNow: null, - suffixAgo: "ago", - suffixFromNow: "from now", - inPast: "any moment now", - seconds: "less than a minute", - minute: "about a minute", - minutes: "%d minutes", - hour: "about an hour", - hours: "about %d hours", - day: "a day", - days: "%d days", - month: "about a month", - months: "%d months", - year: "about a year", - years: "%d years", - wordSeparator: " ", - numbers: [] - } - }, - - inWords: function(distanceMillis) { - if (!this.settings.allowPast && ! this.settings.allowFuture) { - throw 'timeago allowPast and allowFuture settings can not both be set to false.'; - } - - var $l = this.settings.strings; - var prefix = $l.prefixAgo; - var suffix = $l.suffixAgo; - if (this.settings.allowFuture) { - if (distanceMillis < 0) { - prefix = $l.prefixFromNow; - suffix = $l.suffixFromNow; - } - } - - if (!this.settings.allowPast && distanceMillis >= 0) { - return this.settings.strings.inPast; - } - - var seconds = Math.abs(distanceMillis) / 1000; - var minutes = seconds / 60; - var hours = minutes / 60; - var days = hours / 24; - var years = days / 365; - - function substitute(stringOrFunction, number) { - var string = $.isFunction(stringOrFunction) ? stringOrFunction(number, distanceMillis) : stringOrFunction; - var value = ($l.numbers && $l.numbers[number]) || number; - return string.replace(/%d/i, value); - } - - var words = seconds < 45 && substitute($l.seconds, Math.round(seconds)) || - seconds < 90 && substitute($l.minute, 1) || - minutes < 45 && substitute($l.minutes, Math.round(minutes)) || - minutes < 90 && substitute($l.hour, 1) || - hours < 24 && substitute($l.hours, Math.round(hours)) || - hours < 42 && substitute($l.day, 1) || - days < 30 && substitute($l.days, Math.round(days)) || - days < 45 && substitute($l.month, 1) || - days < 365 && substitute($l.months, Math.round(days / 30)) || - years < 1.5 && substitute($l.year, 1) || - substitute($l.years, Math.round(years)); - - var separator = $l.wordSeparator || ""; - if ($l.wordSeparator === undefined) { separator = " "; } - return $.trim([prefix, words, suffix].join(separator)); - }, - - parse: function(iso8601) { - var s = $.trim(iso8601); - s = s.replace(/\.\d+/,""); // remove milliseconds - s = s.replace(/-/,"/").replace(/-/,"/"); - s = s.replace(/T/," ").replace(/Z/," UTC"); - s = s.replace(/([\+\-]\d\d)\:?(\d\d)/," $1$2"); // -04:00 -> -0400 - s = s.replace(/([\+\-]\d\d)$/," $100"); // +09 -> +0900 - return new Date(s); - }, - datetime: function(elem) { - var iso8601 = $t.isTime(elem) ? $(elem).attr("datetime") : $(elem).attr("title"); - return $t.parse(iso8601); - }, - isTime: function(elem) { - // jQuery's `is()` doesn't play well with HTML5 in IE - return $(elem).get(0).tagName.toLowerCase() === "time"; // $(elem).is("time"); - } - }); - - // functions that can be called via $(el).timeago('action') - // init is default when no action is given - // functions are called with context of a single element - var functions = { - init: function() { - functions.dispose.call(this); - var refresh_el = $.proxy(refresh, this); - refresh_el(); - var $s = $t.settings; - if ($s.refreshMillis > 0) { - this._timeagoInterval = setInterval(refresh_el, $s.refreshMillis); - } - }, - update: function(timestamp) { - var date = (timestamp instanceof Date) ? timestamp : $t.parse(timestamp); - $(this).data('timeago', { datetime: date }); - if ($t.settings.localeTitle) { - $(this).attr("title", date.toLocaleString()); - } - refresh.apply(this); - }, - updateFromDOM: function() { - $(this).data('timeago', { datetime: $t.parse( $t.isTime(this) ? $(this).attr("datetime") : $(this).attr("title") ) }); - refresh.apply(this); - }, - dispose: function () { - if (this._timeagoInterval) { - window.clearInterval(this._timeagoInterval); - this._timeagoInterval = null; - } - } - }; - - $.fn.timeago = function(action, options) { - var fn = action ? functions[action] : functions.init; - if (!fn) { - throw new Error("Unknown function name '"+ action +"' for timeago"); - } - // each over objects here and call the requested function - this.each(function() { - fn.call(this, options); - }); - return this; - }; - - function refresh() { - var $s = $t.settings; - - //check if it's still visible - if ($s.autoDispose && !$.contains(document.documentElement,this)) { - //stop if it has been removed - $(this).timeago("dispose"); - return this; - } - - var data = prepareData(this); - - if (!isNaN(data.datetime)) { - if ( $s.cutoff === 0 || Math.abs(distance(data.datetime)) < $s.cutoff) { - $(this).text(inWords(data.datetime)); - } else { - if ($(this).attr('title').length > 0) { - $(this).text($(this).attr('title')); - } - } - } - return this; - } - - function prepareData(element) { - element = $(element); - if (!element.data("timeago")) { - element.data("timeago", { datetime: $t.datetime(element) }); - var text = $.trim(element.text()); - if ($t.settings.localeTitle) { - element.attr("title", element.data('timeago').datetime.toLocaleString()); - } else if (text.length > 0 && !($t.isTime(element) && element.attr("title"))) { - element.attr("title", text); - } - } - return element.data("timeago"); - } - - function inWords(date) { - return $t.inWords(distance(date)); - } - - function distance(date) { - return (new Date().getTime() - date.getTime()); - } - - // fix for IE6 suckage - document.createElement("abbr"); - document.createElement("time"); -})); diff --git a/libs/parsedown/Parsedown.php b/libs/parsedown/Parsedown.php deleted file mode 100644 index b8adb05..0000000 --- a/libs/parsedown/Parsedown.php +++ /dev/null @@ -1,1980 +0,0 @@ -textElements($text); - - # convert to markup - $markup = $this->elements($Elements); - - # trim line breaks - $markup = trim($markup, "\n"); - - return $markup; - } - - protected function textElements($text) - { - # make sure no definitions are set - $this->DefinitionData = array(); - - # standardize line breaks - $text = str_replace(array("\r\n", "\r"), "\n", $text); - - # remove surrounding line breaks - $text = trim($text, "\n"); - - # split text into lines - $lines = explode("\n", $text); - - # iterate through lines to identify blocks - return $this->linesElements($lines); - } - - # - # Setters - # - - function setBreaksEnabled($breaksEnabled) - { - $this->breaksEnabled = $breaksEnabled; - - return $this; - } - - protected $breaksEnabled; - - function setMarkupEscaped($markupEscaped) - { - $this->markupEscaped = $markupEscaped; - - return $this; - } - - protected $markupEscaped; - - function setUrlsLinked($urlsLinked) - { - $this->urlsLinked = $urlsLinked; - - return $this; - } - - protected $urlsLinked = true; - - function setSafeMode($safeMode) - { - $this->safeMode = (bool) $safeMode; - - return $this; - } - - protected $safeMode; - - function setStrictMode($strictMode) - { - $this->strictMode = (bool) $strictMode; - - return $this; - } - - protected $strictMode; - - protected $safeLinksWhitelist = array( - 'http://', - 'https://', - 'ftp://', - 'ftps://', - 'mailto:', - 'tel:', - 'data:image/png;base64,', - 'data:image/gif;base64,', - 'data:image/jpeg;base64,', - 'irc:', - 'ircs:', - 'git:', - 'ssh:', - 'news:', - 'steam:', - ); - - # - # Lines - # - - protected $BlockTypes = array( - '#' => array('Header'), - '*' => array('Rule', 'List'), - '+' => array('List'), - '-' => array('SetextHeader', 'Table', 'Rule', 'List'), - '0' => array('List'), - '1' => array('List'), - '2' => array('List'), - '3' => array('List'), - '4' => array('List'), - '5' => array('List'), - '6' => array('List'), - '7' => array('List'), - '8' => array('List'), - '9' => array('List'), - ':' => array('Table'), - '<' => array('Comment', 'Markup'), - '=' => array('SetextHeader'), - '>' => array('Quote'), - '[' => array('Reference'), - '_' => array('Rule'), - '`' => array('FencedCode'), - '|' => array('Table'), - '~' => array('FencedCode'), - ); - - # ~ - - protected $unmarkedBlockTypes = array( - 'Code', - ); - - # - # Blocks - # - - protected function lines(array $lines) - { - return $this->elements($this->linesElements($lines)); - } - - protected function linesElements(array $lines) - { - $Elements = array(); - $CurrentBlock = null; - - foreach ($lines as $line) - { - if (chop($line) === '') - { - if (isset($CurrentBlock)) - { - $CurrentBlock['interrupted'] = (isset($CurrentBlock['interrupted']) - ? $CurrentBlock['interrupted'] + 1 : 1 - ); - } - - continue; - } - - while (($beforeTab = strstr($line, "\t", true)) !== false) - { - $shortage = 4 - mb_strlen($beforeTab, 'utf-8') % 4; - - $line = $beforeTab - . str_repeat(' ', $shortage) - . substr($line, strlen($beforeTab) + 1) - ; - } - - $indent = strspn($line, ' '); - - $text = $indent > 0 ? substr($line, $indent) : $line; - - # ~ - - $Line = array('body' => $line, 'indent' => $indent, 'text' => $text); - - # ~ - - if (isset($CurrentBlock['continuable'])) - { - $methodName = 'block' . $CurrentBlock['type'] . 'Continue'; - $Block = $this->$methodName($Line, $CurrentBlock); - - if (isset($Block)) - { - $CurrentBlock = $Block; - - continue; - } - else - { - if ($this->isBlockCompletable($CurrentBlock['type'])) - { - $methodName = 'block' . $CurrentBlock['type'] . 'Complete'; - $CurrentBlock = $this->$methodName($CurrentBlock); - } - } - } - - # ~ - - $marker = $text[0]; - - # ~ - - $blockTypes = $this->unmarkedBlockTypes; - - if (isset($this->BlockTypes[$marker])) - { - foreach ($this->BlockTypes[$marker] as $blockType) - { - $blockTypes []= $blockType; - } - } - - # - # ~ - - foreach ($blockTypes as $blockType) - { - $Block = $this->{"block$blockType"}($Line, $CurrentBlock); - - if (isset($Block)) - { - $Block['type'] = $blockType; - - if ( ! isset($Block['identified'])) - { - if (isset($CurrentBlock)) - { - $Elements[] = $this->extractElement($CurrentBlock); - } - - $Block['identified'] = true; - } - - if ($this->isBlockContinuable($blockType)) - { - $Block['continuable'] = true; - } - - $CurrentBlock = $Block; - - continue 2; - } - } - - # ~ - - if (isset($CurrentBlock) and $CurrentBlock['type'] === 'Paragraph') - { - $Block = $this->paragraphContinue($Line, $CurrentBlock); - } - - if (isset($Block)) - { - $CurrentBlock = $Block; - } - else - { - if (isset($CurrentBlock)) - { - $Elements[] = $this->extractElement($CurrentBlock); - } - - $CurrentBlock = $this->paragraph($Line); - - $CurrentBlock['identified'] = true; - } - } - - # ~ - - if (isset($CurrentBlock['continuable']) and $this->isBlockCompletable($CurrentBlock['type'])) - { - $methodName = 'block' . $CurrentBlock['type'] . 'Complete'; - $CurrentBlock = $this->$methodName($CurrentBlock); - } - - # ~ - - if (isset($CurrentBlock)) - { - $Elements[] = $this->extractElement($CurrentBlock); - } - - # ~ - - return $Elements; - } - - protected function extractElement(array $Component) - { - if ( ! isset($Component['element'])) - { - if (isset($Component['markup'])) - { - $Component['element'] = array('rawHtml' => $Component['markup']); - } - elseif (isset($Component['hidden'])) - { - $Component['element'] = array(); - } - } - - return $Component['element']; - } - - protected function isBlockContinuable($Type) - { - return method_exists($this, 'block' . $Type . 'Continue'); - } - - protected function isBlockCompletable($Type) - { - return method_exists($this, 'block' . $Type . 'Complete'); - } - - # - # Code - - protected function blockCode($Line, $Block = null) - { - if (isset($Block) and $Block['type'] === 'Paragraph' and ! isset($Block['interrupted'])) - { - return; - } - - if ($Line['indent'] >= 4) - { - $text = substr($Line['body'], 4); - - $Block = array( - 'element' => array( - 'name' => 'pre', - 'element' => array( - 'name' => 'code', - 'text' => $text, - ), - ), - ); - - return $Block; - } - } - - protected function blockCodeContinue($Line, $Block) - { - if ($Line['indent'] >= 4) - { - if (isset($Block['interrupted'])) - { - $Block['element']['element']['text'] .= str_repeat("\n", $Block['interrupted']); - - unset($Block['interrupted']); - } - - $Block['element']['element']['text'] .= "\n"; - - $text = substr($Line['body'], 4); - - $Block['element']['element']['text'] .= $text; - - return $Block; - } - } - - protected function blockCodeComplete($Block) - { - return $Block; - } - - # - # Comment - - protected function blockComment($Line) - { - if ($this->markupEscaped or $this->safeMode) - { - return; - } - - if (strpos($Line['text'], '') !== false) - { - $Block['closed'] = true; - } - - return $Block; - } - } - - protected function blockCommentContinue($Line, array $Block) - { - if (isset($Block['closed'])) - { - return; - } - - $Block['element']['rawHtml'] .= "\n" . $Line['body']; - - if (strpos($Line['text'], '-->') !== false) - { - $Block['closed'] = true; - } - - return $Block; - } - - # - # Fenced Code - - protected function blockFencedCode($Line) - { - $marker = $Line['text'][0]; - - $openerLength = strspn($Line['text'], $marker); - - if ($openerLength < 3) - { - return; - } - - $infostring = trim(substr($Line['text'], $openerLength), "\t "); - - if (strpos($infostring, '`') !== false) - { - return; - } - - $Element = array( - 'name' => 'code', - 'text' => '', - ); - - if ($infostring !== '') - { - $Element['attributes'] = array('class' => "language-$infostring"); - } - - $Block = array( - 'char' => $marker, - 'openerLength' => $openerLength, - 'element' => array( - 'name' => 'pre', - 'element' => $Element, - ), - ); - - return $Block; - } - - protected function blockFencedCodeContinue($Line, $Block) - { - if (isset($Block['complete'])) - { - return; - } - - if (isset($Block['interrupted'])) - { - $Block['element']['element']['text'] .= str_repeat("\n", $Block['interrupted']); - - unset($Block['interrupted']); - } - - if (($len = strspn($Line['text'], $Block['char'])) >= $Block['openerLength'] - and chop(substr($Line['text'], $len), ' ') === '' - ) { - $Block['element']['element']['text'] = substr($Block['element']['element']['text'], 1); - - $Block['complete'] = true; - - return $Block; - } - - $Block['element']['element']['text'] .= "\n" . $Line['body']; - - return $Block; - } - - protected function blockFencedCodeComplete($Block) - { - return $Block; - } - - # - # Header - - protected function blockHeader($Line) - { - $level = strspn($Line['text'], '#'); - - if ($level > 6) - { - return; - } - - $text = trim($Line['text'], '#'); - - if ($this->strictMode and isset($text[0]) and $text[0] !== ' ') - { - return; - } - - $text = trim($text, ' '); - - $Block = array( - 'element' => array( - 'name' => 'h' . $level, - 'handler' => array( - 'function' => 'lineElements', - 'argument' => $text, - 'destination' => 'elements', - ) - ), - ); - - return $Block; - } - - # - # List - - protected function blockList($Line, array $CurrentBlock = null) - { - list($name, $pattern) = $Line['text'][0] <= '-' ? array('ul', '[*+-]') : array('ol', '[0-9]{1,9}+[.\)]'); - - if (preg_match('/^('.$pattern.'([ ]++|$))(.*+)/', $Line['text'], $matches)) - { - $contentIndent = strlen($matches[2]); - - if ($contentIndent >= 5) - { - $contentIndent -= 1; - $matches[1] = substr($matches[1], 0, -$contentIndent); - $matches[3] = str_repeat(' ', $contentIndent) . $matches[3]; - } - elseif ($contentIndent === 0) - { - $matches[1] .= ' '; - } - - $markerWithoutWhitespace = strstr($matches[1], ' ', true); - - $Block = array( - 'indent' => $Line['indent'], - 'pattern' => $pattern, - 'data' => array( - 'type' => $name, - 'marker' => $matches[1], - 'markerType' => ($name === 'ul' ? $markerWithoutWhitespace : substr($markerWithoutWhitespace, -1)), - ), - 'element' => array( - 'name' => $name, - 'elements' => array(), - ), - ); - $Block['data']['markerTypeRegex'] = preg_quote($Block['data']['markerType'], '/'); - - if ($name === 'ol') - { - $listStart = ltrim(strstr($matches[1], $Block['data']['markerType'], true), '0') ?: '0'; - - if ($listStart !== '1') - { - if ( - isset($CurrentBlock) - and $CurrentBlock['type'] === 'Paragraph' - and ! isset($CurrentBlock['interrupted']) - ) { - return; - } - - $Block['element']['attributes'] = array('start' => $listStart); - } - } - - $Block['li'] = array( - 'name' => 'li', - 'handler' => array( - 'function' => 'li', - 'argument' => !empty($matches[3]) ? array($matches[3]) : array(), - 'destination' => 'elements' - ) - ); - - $Block['element']['elements'] []= & $Block['li']; - - return $Block; - } - } - - protected function blockListContinue($Line, array $Block) - { - if (isset($Block['interrupted']) and empty($Block['li']['handler']['argument'])) - { - return null; - } - - $requiredIndent = ($Block['indent'] + strlen($Block['data']['marker'])); - - if ($Line['indent'] < $requiredIndent - and ( - ( - $Block['data']['type'] === 'ol' - and preg_match('/^[0-9]++'.$Block['data']['markerTypeRegex'].'(?:[ ]++(.*)|$)/', $Line['text'], $matches) - ) or ( - $Block['data']['type'] === 'ul' - and preg_match('/^'.$Block['data']['markerTypeRegex'].'(?:[ ]++(.*)|$)/', $Line['text'], $matches) - ) - ) - ) { - if (isset($Block['interrupted'])) - { - $Block['li']['handler']['argument'] []= ''; - - $Block['loose'] = true; - - unset($Block['interrupted']); - } - - unset($Block['li']); - - $text = isset($matches[1]) ? $matches[1] : ''; - - $Block['indent'] = $Line['indent']; - - $Block['li'] = array( - 'name' => 'li', - 'handler' => array( - 'function' => 'li', - 'argument' => array($text), - 'destination' => 'elements' - ) - ); - - $Block['element']['elements'] []= & $Block['li']; - - return $Block; - } - elseif ($Line['indent'] < $requiredIndent and $this->blockList($Line)) - { - return null; - } - - if ($Line['text'][0] === '[' and $this->blockReference($Line)) - { - return $Block; - } - - if ($Line['indent'] >= $requiredIndent) - { - if (isset($Block['interrupted'])) - { - $Block['li']['handler']['argument'] []= ''; - - $Block['loose'] = true; - - unset($Block['interrupted']); - } - - $text = substr($Line['body'], $requiredIndent); - - $Block['li']['handler']['argument'] []= $text; - - return $Block; - } - - if ( ! isset($Block['interrupted'])) - { - $text = preg_replace('/^[ ]{0,'.$requiredIndent.'}+/', '', $Line['body']); - - $Block['li']['handler']['argument'] []= $text; - - return $Block; - } - } - - protected function blockListComplete(array $Block) - { - if (isset($Block['loose'])) - { - foreach ($Block['element']['elements'] as &$li) - { - if (end($li['handler']['argument']) !== '') - { - $li['handler']['argument'] []= ''; - } - } - } - - return $Block; - } - - # - # Quote - - protected function blockQuote($Line) - { - if (preg_match('/^>[ ]?+(.*+)/', $Line['text'], $matches)) - { - $Block = array( - 'element' => array( - 'name' => 'blockquote', - 'handler' => array( - 'function' => 'linesElements', - 'argument' => (array) $matches[1], - 'destination' => 'elements', - ) - ), - ); - - return $Block; - } - } - - protected function blockQuoteContinue($Line, array $Block) - { - if (isset($Block['interrupted'])) - { - return; - } - - if ($Line['text'][0] === '>' and preg_match('/^>[ ]?+(.*+)/', $Line['text'], $matches)) - { - $Block['element']['handler']['argument'] []= $matches[1]; - - return $Block; - } - - if ( ! isset($Block['interrupted'])) - { - $Block['element']['handler']['argument'] []= $Line['text']; - - return $Block; - } - } - - # - # Rule - - protected function blockRule($Line) - { - $marker = $Line['text'][0]; - - if (substr_count($Line['text'], $marker) >= 3 and chop($Line['text'], " $marker") === '') - { - $Block = array( - 'element' => array( - 'name' => 'hr', - ), - ); - - return $Block; - } - } - - # - # Setext - - protected function blockSetextHeader($Line, array $Block = null) - { - if ( ! isset($Block) or $Block['type'] !== 'Paragraph' or isset($Block['interrupted'])) - { - return; - } - - if ($Line['indent'] < 4 and chop(chop($Line['text'], ' '), $Line['text'][0]) === '') - { - $Block['element']['name'] = $Line['text'][0] === '=' ? 'h1' : 'h2'; - - return $Block; - } - } - - # - # Markup - - protected function blockMarkup($Line) - { - if ($this->markupEscaped or $this->safeMode) - { - return; - } - - if (preg_match('/^<[\/]?+(\w*)(?:[ ]*+'.$this->regexHtmlAttribute.')*+[ ]*+(\/)?>/', $Line['text'], $matches)) - { - $element = strtolower($matches[1]); - - if (in_array($element, $this->textLevelElements)) - { - return; - } - - $Block = array( - 'name' => $matches[1], - 'element' => array( - 'rawHtml' => $Line['text'], - 'autobreak' => true, - ), - ); - - return $Block; - } - } - - protected function blockMarkupContinue($Line, array $Block) - { - if (isset($Block['closed']) or isset($Block['interrupted'])) - { - return; - } - - $Block['element']['rawHtml'] .= "\n" . $Line['body']; - - return $Block; - } - - # - # Reference - - protected function blockReference($Line) - { - if (strpos($Line['text'], ']') !== false - and preg_match('/^\[(.+?)\]:[ ]*+?(?:[ ]+["\'(](.+)["\')])?[ ]*+$/', $Line['text'], $matches) - ) { - $id = strtolower($matches[1]); - - $Data = array( - 'url' => $matches[2], - 'title' => isset($matches[3]) ? $matches[3] : null, - ); - - $this->DefinitionData['Reference'][$id] = $Data; - - $Block = array( - 'element' => array(), - ); - - return $Block; - } - } - - # - # Table - - protected function blockTable($Line, array $Block = null) - { - if ( ! isset($Block) or $Block['type'] !== 'Paragraph' or isset($Block['interrupted'])) - { - return; - } - - if ( - strpos($Block['element']['handler']['argument'], '|') === false - and strpos($Line['text'], '|') === false - and strpos($Line['text'], ':') === false - or strpos($Block['element']['handler']['argument'], "\n") !== false - ) { - return; - } - - if (chop($Line['text'], ' -:|') !== '') - { - return; - } - - $alignments = array(); - - $divider = $Line['text']; - - $divider = trim($divider); - $divider = trim($divider, '|'); - - $dividerCells = explode('|', $divider); - - foreach ($dividerCells as $dividerCell) - { - $dividerCell = trim($dividerCell); - - if ($dividerCell === '') - { - return; - } - - $alignment = null; - - if ($dividerCell[0] === ':') - { - $alignment = 'left'; - } - - if (substr($dividerCell, - 1) === ':') - { - $alignment = $alignment === 'left' ? 'center' : 'right'; - } - - $alignments []= $alignment; - } - - # ~ - - $HeaderElements = array(); - - $header = $Block['element']['handler']['argument']; - - $header = trim($header); - $header = trim($header, '|'); - - $headerCells = explode('|', $header); - - if (count($headerCells) !== count($alignments)) - { - return; - } - - foreach ($headerCells as $index => $headerCell) - { - $headerCell = trim($headerCell); - - $HeaderElement = array( - 'name' => 'th', - 'handler' => array( - 'function' => 'lineElements', - 'argument' => $headerCell, - 'destination' => 'elements', - ) - ); - - if (isset($alignments[$index])) - { - $alignment = $alignments[$index]; - - $HeaderElement['attributes'] = array( - 'style' => "text-align: $alignment;", - ); - } - - $HeaderElements []= $HeaderElement; - } - - # ~ - - $Block = array( - 'alignments' => $alignments, - 'identified' => true, - 'element' => array( - 'name' => 'table', - 'elements' => array(), - ), - ); - - $Block['element']['elements'] []= array( - 'name' => 'thead', - ); - - $Block['element']['elements'] []= array( - 'name' => 'tbody', - 'elements' => array(), - ); - - $Block['element']['elements'][0]['elements'] []= array( - 'name' => 'tr', - 'elements' => $HeaderElements, - ); - - return $Block; - } - - protected function blockTableContinue($Line, array $Block) - { - if (isset($Block['interrupted'])) - { - return; - } - - if (count($Block['alignments']) === 1 or $Line['text'][0] === '|' or strpos($Line['text'], '|')) - { - $Elements = array(); - - $row = $Line['text']; - - $row = trim($row); - $row = trim($row, '|'); - - preg_match_all('/(?:(\\\\[|])|[^|`]|`[^`]++`|`)++/', $row, $matches); - - $cells = array_slice($matches[0], 0, count($Block['alignments'])); - - foreach ($cells as $index => $cell) - { - $cell = trim($cell); - - $Element = array( - 'name' => 'td', - 'handler' => array( - 'function' => 'lineElements', - 'argument' => $cell, - 'destination' => 'elements', - ) - ); - - if (isset($Block['alignments'][$index])) - { - $Element['attributes'] = array( - 'style' => 'text-align: ' . $Block['alignments'][$index] . ';', - ); - } - - $Elements []= $Element; - } - - $Element = array( - 'name' => 'tr', - 'elements' => $Elements, - ); - - $Block['element']['elements'][1]['elements'] []= $Element; - - return $Block; - } - } - - # - # ~ - # - - protected function paragraph($Line) - { - return array( - 'type' => 'Paragraph', - 'element' => array( - 'name' => 'p', - 'handler' => array( - 'function' => 'lineElements', - 'argument' => $Line['text'], - 'destination' => 'elements', - ), - ), - ); - } - - protected function paragraphContinue($Line, array $Block) - { - if (isset($Block['interrupted'])) - { - return; - } - - $Block['element']['handler']['argument'] .= "\n".$Line['text']; - - return $Block; - } - - # - # Inline Elements - # - - protected $InlineTypes = array( - '!' => array('Image'), - '&' => array('SpecialCharacter'), - '*' => array('Emphasis'), - ':' => array('Url'), - '<' => array('UrlTag', 'EmailTag', 'Markup'), - '[' => array('Link'), - '_' => array('Emphasis'), - '`' => array('Code'), - '~' => array('Strikethrough'), - '\\' => array('EscapeSequence'), - ); - - # ~ - - protected $inlineMarkerList = '!*_&[:<`~\\'; - - # - # ~ - # - - public function line($text, $nonNestables = array()) - { - return $this->elements($this->lineElements($text, $nonNestables)); - } - - protected function lineElements($text, $nonNestables = array()) - { - # standardize line breaks - $text = str_replace(array("\r\n", "\r"), "\n", $text); - - $Elements = array(); - - $nonNestables = (empty($nonNestables) - ? array() - : array_combine($nonNestables, $nonNestables) - ); - - # $excerpt is based on the first occurrence of a marker - - while ($excerpt = strpbrk($text, $this->inlineMarkerList)) - { - $marker = $excerpt[0]; - - $markerPosition = strlen($text) - strlen($excerpt); - - $Excerpt = array('text' => $excerpt, 'context' => $text); - - foreach ($this->InlineTypes[$marker] as $inlineType) - { - # check to see if the current inline type is nestable in the current context - - if (isset($nonNestables[$inlineType])) - { - continue; - } - - $Inline = $this->{"inline$inlineType"}($Excerpt); - - if ( ! isset($Inline)) - { - continue; - } - - # makes sure that the inline belongs to "our" marker - - if (isset($Inline['position']) and $Inline['position'] > $markerPosition) - { - continue; - } - - # sets a default inline position - - if ( ! isset($Inline['position'])) - { - $Inline['position'] = $markerPosition; - } - - # cause the new element to 'inherit' our non nestables - - - $Inline['element']['nonNestables'] = isset($Inline['element']['nonNestables']) - ? array_merge($Inline['element']['nonNestables'], $nonNestables) - : $nonNestables - ; - - # the text that comes before the inline - $unmarkedText = substr($text, 0, $Inline['position']); - - # compile the unmarked text - $InlineText = $this->inlineText($unmarkedText); - $Elements[] = $InlineText['element']; - - # compile the inline - $Elements[] = $this->extractElement($Inline); - - # remove the examined text - $text = substr($text, $Inline['position'] + $Inline['extent']); - - continue 2; - } - - # the marker does not belong to an inline - - $unmarkedText = substr($text, 0, $markerPosition + 1); - - $InlineText = $this->inlineText($unmarkedText); - $Elements[] = $InlineText['element']; - - $text = substr($text, $markerPosition + 1); - } - - $InlineText = $this->inlineText($text); - $Elements[] = $InlineText['element']; - - foreach ($Elements as &$Element) - { - if ( ! isset($Element['autobreak'])) - { - $Element['autobreak'] = false; - } - } - - return $Elements; - } - - # - # ~ - # - - protected function inlineText($text) - { - $Inline = array( - 'extent' => strlen($text), - 'element' => array(), - ); - - $Inline['element']['elements'] = self::pregReplaceElements( - $this->breaksEnabled ? '/[ ]*+\n/' : '/(?:[ ]*+\\\\|[ ]{2,}+)\n/', - array( - array('name' => 'br'), - array('text' => "\n"), - ), - $text - ); - - return $Inline; - } - - protected function inlineCode($Excerpt) - { - $marker = $Excerpt['text'][0]; - - if (preg_match('/^(['.$marker.']++)[ ]*+(.+?)[ ]*+(? strlen($matches[0]), - 'element' => array( - 'name' => 'code', - 'text' => $text, - ), - ); - } - } - - protected function inlineEmailTag($Excerpt) - { - $hostnameLabel = '[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?'; - - $commonMarkEmail = '[a-zA-Z0-9.!#$%&\'*+\/=?^_`{|}~-]++@' - . $hostnameLabel . '(?:\.' . $hostnameLabel . ')*'; - - if (strpos($Excerpt['text'], '>') !== false - and preg_match("/^<((mailto:)?$commonMarkEmail)>/i", $Excerpt['text'], $matches) - ){ - $url = $matches[1]; - - if ( ! isset($matches[2])) - { - $url = "mailto:$url"; - } - - return array( - 'extent' => strlen($matches[0]), - 'element' => array( - 'name' => 'a', - 'text' => $matches[1], - 'attributes' => array( - 'href' => $url, - ), - ), - ); - } - } - - protected function inlineEmphasis($Excerpt) - { - if ( ! isset($Excerpt['text'][1])) - { - return; - } - - $marker = $Excerpt['text'][0]; - - if ($Excerpt['text'][1] === $marker and preg_match($this->StrongRegex[$marker], $Excerpt['text'], $matches)) - { - $emphasis = 'strong'; - } - elseif (preg_match($this->EmRegex[$marker], $Excerpt['text'], $matches)) - { - $emphasis = 'em'; - } - else - { - return; - } - - return array( - 'extent' => strlen($matches[0]), - 'element' => array( - 'name' => $emphasis, - 'handler' => array( - 'function' => 'lineElements', - 'argument' => $matches[1], - 'destination' => 'elements', - ) - ), - ); - } - - protected function inlineEscapeSequence($Excerpt) - { - if (isset($Excerpt['text'][1]) and in_array($Excerpt['text'][1], $this->specialCharacters)) - { - return array( - 'element' => array('rawHtml' => $Excerpt['text'][1]), - 'extent' => 2, - ); - } - } - - protected function inlineImage($Excerpt) - { - if ( ! isset($Excerpt['text'][1]) or $Excerpt['text'][1] !== '[') - { - return; - } - - $Excerpt['text']= substr($Excerpt['text'], 1); - - $Link = $this->inlineLink($Excerpt); - - if ($Link === null) - { - return; - } - - $Inline = array( - 'extent' => $Link['extent'] + 1, - 'element' => array( - 'name' => 'img', - 'attributes' => array( - 'src' => $Link['element']['attributes']['href'], - 'alt' => $Link['element']['handler']['argument'], - ), - 'autobreak' => true, - ), - ); - - $Inline['element']['attributes'] += $Link['element']['attributes']; - - unset($Inline['element']['attributes']['href']); - - return $Inline; - } - - protected function inlineLink($Excerpt) - { - $Element = array( - 'name' => 'a', - 'handler' => array( - 'function' => 'lineElements', - 'argument' => null, - 'destination' => 'elements', - ), - 'nonNestables' => array('Url', 'Link'), - 'attributes' => array( - 'href' => null, - 'title' => null, - ), - ); - - $extent = 0; - - $remainder = $Excerpt['text']; - - if (preg_match('/\[((?:[^][]++|(?R))*+)\]/', $remainder, $matches)) - { - $Element['handler']['argument'] = $matches[1]; - - $extent += strlen($matches[0]); - - $remainder = substr($remainder, $extent); - } - else - { - return; - } - - if (preg_match('/^[(]\s*+((?:[^ ()]++|[(][^ )]+[)])++)(?:[ ]+("[^"]*+"|\'[^\']*+\'))?\s*+[)]/', $remainder, $matches)) - { - $Element['attributes']['href'] = $matches[1]; - - if (isset($matches[2])) - { - $Element['attributes']['title'] = substr($matches[2], 1, - 1); - } - - $extent += strlen($matches[0]); - } - else - { - if (preg_match('/^\s*\[(.*?)\]/', $remainder, $matches)) - { - $definition = strlen($matches[1]) ? $matches[1] : $Element['handler']['argument']; - $definition = strtolower($definition); - - $extent += strlen($matches[0]); - } - else - { - $definition = strtolower($Element['handler']['argument']); - } - - if ( ! isset($this->DefinitionData['Reference'][$definition])) - { - return; - } - - $Definition = $this->DefinitionData['Reference'][$definition]; - - $Element['attributes']['href'] = $Definition['url']; - $Element['attributes']['title'] = $Definition['title']; - } - - return array( - 'extent' => $extent, - 'element' => $Element, - ); - } - - protected function inlineMarkup($Excerpt) - { - if ($this->markupEscaped or $this->safeMode or strpos($Excerpt['text'], '>') === false) - { - return; - } - - if ($Excerpt['text'][1] === '/' and preg_match('/^<\/\w[\w-]*+[ ]*+>/s', $Excerpt['text'], $matches)) - { - return array( - 'element' => array('rawHtml' => $matches[0]), - 'extent' => strlen($matches[0]), - ); - } - - if ($Excerpt['text'][1] === '!' and preg_match('/^/s', $Excerpt['text'], $matches)) - { - return array( - 'element' => array('rawHtml' => $matches[0]), - 'extent' => strlen($matches[0]), - ); - } - - if ($Excerpt['text'][1] !== ' ' and preg_match('/^<\w[\w-]*+(?:[ ]*+'.$this->regexHtmlAttribute.')*+[ ]*+\/?>/s', $Excerpt['text'], $matches)) - { - return array( - 'element' => array('rawHtml' => $matches[0]), - 'extent' => strlen($matches[0]), - ); - } - } - - protected function inlineSpecialCharacter($Excerpt) - { - if (substr($Excerpt['text'], 1, 1) !== ' ' and strpos($Excerpt['text'], ';') !== false - and preg_match('/^&(#?+[0-9a-zA-Z]++);/', $Excerpt['text'], $matches) - ) { - return array( - 'element' => array('rawHtml' => '&' . $matches[1] . ';'), - 'extent' => strlen($matches[0]), - ); - } - - return; - } - - protected function inlineStrikethrough($Excerpt) - { - if ( ! isset($Excerpt['text'][1])) - { - return; - } - - if ($Excerpt['text'][1] === '~' and preg_match('/^~~(?=\S)(.+?)(?<=\S)~~/', $Excerpt['text'], $matches)) - { - return array( - 'extent' => strlen($matches[0]), - 'element' => array( - 'name' => 'del', - 'handler' => array( - 'function' => 'lineElements', - 'argument' => $matches[1], - 'destination' => 'elements', - ) - ), - ); - } - } - - protected function inlineUrl($Excerpt) - { - if ($this->urlsLinked !== true or ! isset($Excerpt['text'][2]) or $Excerpt['text'][2] !== '/') - { - return; - } - - if (strpos($Excerpt['context'], 'http') !== false - and preg_match('/\bhttps?+:[\/]{2}[^\s<]+\b\/*+/ui', $Excerpt['context'], $matches, PREG_OFFSET_CAPTURE) - ) { - $url = $matches[0][0]; - - $Inline = array( - 'extent' => strlen($matches[0][0]), - 'position' => $matches[0][1], - 'element' => array( - 'name' => 'a', - 'text' => $url, - 'attributes' => array( - 'href' => $url, - ), - ), - ); - - return $Inline; - } - } - - protected function inlineUrlTag($Excerpt) - { - if (strpos($Excerpt['text'], '>') !== false and preg_match('/^<(\w++:\/{2}[^ >]++)>/i', $Excerpt['text'], $matches)) - { - $url = $matches[1]; - - return array( - 'extent' => strlen($matches[0]), - 'element' => array( - 'name' => 'a', - 'text' => $url, - 'attributes' => array( - 'href' => $url, - ), - ), - ); - } - } - - # ~ - - protected function unmarkedText($text) - { - $Inline = $this->inlineText($text); - return $this->element($Inline['element']); - } - - # - # Handlers - # - - protected function handle(array $Element) - { - if (isset($Element['handler'])) - { - if (!isset($Element['nonNestables'])) - { - $Element['nonNestables'] = array(); - } - - if (is_string($Element['handler'])) - { - $function = $Element['handler']; - $argument = $Element['text']; - unset($Element['text']); - $destination = 'rawHtml'; - } - else - { - $function = $Element['handler']['function']; - $argument = $Element['handler']['argument']; - $destination = $Element['handler']['destination']; - } - - $Element[$destination] = $this->{$function}($argument, $Element['nonNestables']); - - if ($destination === 'handler') - { - $Element = $this->handle($Element); - } - - unset($Element['handler']); - } - - return $Element; - } - - protected function handleElementRecursive(array $Element) - { - return $this->elementApplyRecursive(array($this, 'handle'), $Element); - } - - protected function handleElementsRecursive(array $Elements) - { - return $this->elementsApplyRecursive(array($this, 'handle'), $Elements); - } - - protected function elementApplyRecursive($closure, array $Element) - { - $Element = call_user_func($closure, $Element); - - if (isset($Element['elements'])) - { - $Element['elements'] = $this->elementsApplyRecursive($closure, $Element['elements']); - } - elseif (isset($Element['element'])) - { - $Element['element'] = $this->elementApplyRecursive($closure, $Element['element']); - } - - return $Element; - } - - protected function elementApplyRecursiveDepthFirst($closure, array $Element) - { - if (isset($Element['elements'])) - { - $Element['elements'] = $this->elementsApplyRecursiveDepthFirst($closure, $Element['elements']); - } - elseif (isset($Element['element'])) - { - $Element['element'] = $this->elementsApplyRecursiveDepthFirst($closure, $Element['element']); - } - - $Element = call_user_func($closure, $Element); - - return $Element; - } - - protected function elementsApplyRecursive($closure, array $Elements) - { - foreach ($Elements as &$Element) - { - $Element = $this->elementApplyRecursive($closure, $Element); - } - - return $Elements; - } - - protected function elementsApplyRecursiveDepthFirst($closure, array $Elements) - { - foreach ($Elements as &$Element) - { - $Element = $this->elementApplyRecursiveDepthFirst($closure, $Element); - } - - return $Elements; - } - - protected function element(array $Element) - { - if ($this->safeMode) - { - $Element = $this->sanitiseElement($Element); - } - - # identity map if element has no handler - $Element = $this->handle($Element); - - $hasName = isset($Element['name']); - - $markup = ''; - - if ($hasName) - { - $markup .= '<' . $Element['name']; - - if (isset($Element['attributes'])) - { - foreach ($Element['attributes'] as $name => $value) - { - if ($value === null) - { - continue; - } - - $markup .= " $name=\"".self::escape($value).'"'; - } - } - } - - $permitRawHtml = false; - - if (isset($Element['text'])) - { - $text = $Element['text']; - } - // very strongly consider an alternative if you're writing an - // extension - elseif (isset($Element['rawHtml'])) - { - $text = $Element['rawHtml']; - - $allowRawHtmlInSafeMode = isset($Element['allowRawHtmlInSafeMode']) && $Element['allowRawHtmlInSafeMode']; - $permitRawHtml = !$this->safeMode || $allowRawHtmlInSafeMode; - } - - $hasContent = isset($text) || isset($Element['element']) || isset($Element['elements']); - - if ($hasContent) - { - $markup .= $hasName ? '>' : ''; - - if (isset($Element['elements'])) - { - $markup .= $this->elements($Element['elements']); - } - elseif (isset($Element['element'])) - { - $markup .= $this->element($Element['element']); - } - else - { - if (!$permitRawHtml) - { - $markup .= self::escape($text, true); - } - else - { - $markup .= $text; - } - } - - $markup .= $hasName ? '' : ''; - } - elseif ($hasName) - { - $markup .= ' />'; - } - - return $markup; - } - - protected function elements(array $Elements) - { - $markup = ''; - - $autoBreak = true; - - foreach ($Elements as $Element) - { - if (empty($Element)) - { - continue; - } - - $autoBreakNext = (isset($Element['autobreak']) - ? $Element['autobreak'] : isset($Element['name']) - ); - // (autobreak === false) covers both sides of an element - $autoBreak = !$autoBreak ? $autoBreak : $autoBreakNext; - - $markup .= ($autoBreak ? "\n" : '') . $this->element($Element); - $autoBreak = $autoBreakNext; - } - - $markup .= $autoBreak ? "\n" : ''; - - return $markup; - } - - # ~ - - protected function li($lines) - { - $Elements = $this->linesElements($lines); - - if ( ! in_array('', $lines) - and isset($Elements[0]) and isset($Elements[0]['name']) - and $Elements[0]['name'] === 'p' - ) { - unset($Elements[0]['name']); - } - - return $Elements; - } - - # - # AST Convenience - # - - /** - * Replace occurrences $regexp with $Elements in $text. Return an array of - * elements representing the replacement. - */ - protected static function pregReplaceElements($regexp, $Elements, $text) - { - $newElements = array(); - - while (preg_match($regexp, $text, $matches, PREG_OFFSET_CAPTURE)) - { - $offset = $matches[0][1]; - $before = substr($text, 0, $offset); - $after = substr($text, $offset + strlen($matches[0][0])); - - $newElements[] = array('text' => $before); - - foreach ($Elements as $Element) - { - $newElements[] = $Element; - } - - $text = $after; - } - - $newElements[] = array('text' => $text); - - return $newElements; - } - - # - # Deprecated Methods - # - - function parse($text) - { - $markup = $this->text($text); - - return $markup; - } - - protected function sanitiseElement(array $Element) - { - static $goodAttribute = '/^[a-zA-Z0-9][a-zA-Z0-9-_]*+$/'; - static $safeUrlNameToAtt = array( - 'a' => 'href', - 'img' => 'src', - ); - - if ( ! isset($Element['name'])) - { - unset($Element['attributes']); - return $Element; - } - - if (isset($safeUrlNameToAtt[$Element['name']])) - { - $Element = $this->filterUnsafeUrlInAttribute($Element, $safeUrlNameToAtt[$Element['name']]); - } - - if ( ! empty($Element['attributes'])) - { - foreach ($Element['attributes'] as $att => $val) - { - # filter out badly parsed attribute - if ( ! preg_match($goodAttribute, $att)) - { - unset($Element['attributes'][$att]); - } - # dump onevent attribute - elseif (self::striAtStart($att, 'on')) - { - unset($Element['attributes'][$att]); - } - } - } - - return $Element; - } - - protected function filterUnsafeUrlInAttribute(array $Element, $attribute) - { - foreach ($this->safeLinksWhitelist as $scheme) - { - if (self::striAtStart($Element['attributes'][$attribute], $scheme)) - { - return $Element; - } - } - - $Element['attributes'][$attribute] = str_replace(':', '%3A', $Element['attributes'][$attribute]); - - return $Element; - } - - # - # Static Methods - # - - protected static function escape($text, $allowQuotes = false) - { - return htmlspecialchars($text, $allowQuotes ? ENT_NOQUOTES : ENT_QUOTES, 'UTF-8'); - } - - protected static function striAtStart($string, $needle) - { - $len = strlen($needle); - - if ($len > strlen($string)) - { - return false; - } - else - { - return strtolower(substr($string, 0, $len)) === strtolower($needle); - } - } - - static function instance($name = 'default') - { - if (isset(self::$instances[$name])) - { - return self::$instances[$name]; - } - - $instance = new static(); - - self::$instances[$name] = $instance; - - return $instance; - } - - private static $instances = array(); - - # - # Fields - # - - protected $DefinitionData; - - # - # Read-Only - - protected $specialCharacters = array( - '\\', '`', '*', '_', '{', '}', '[', ']', '(', ')', '>', '#', '+', '-', '.', '!', '|', '~' - ); - - protected $StrongRegex = array( - '*' => '/^[*]{2}((?:\\\\\*|[^*]|[*][^*]*+[*])+?)[*]{2}(?![*])/s', - '_' => '/^__((?:\\\\_|[^_]|_[^_]*+_)+?)__(?!_)/us', - ); - - protected $EmRegex = array( - '*' => '/^[*]((?:\\\\\*|[^*]|[*][*][^*]+?[*][*])+?)[*](?![*])/s', - '_' => '/^_((?:\\\\_|[^_]|__[^_]*__)+?)_(?!_)\b/us', - ); - - protected $regexHtmlAttribute = '[a-zA-Z_:][\w:.-]*+(?:\s*+=\s*+(?:[^"\'=<>`\s]+|"[^"]*+"|\'[^\']*+\'))?+'; - - protected $voidElements = array( - 'area', 'base', 'br', 'col', 'command', 'embed', 'hr', 'img', 'input', 'link', 'meta', 'param', 'source', - ); - - protected $textLevelElements = array( - 'a', 'br', 'bdo', 'abbr', 'blink', 'nextid', 'acronym', 'basefont', - 'b', 'em', 'big', 'cite', 'small', 'spacer', 'listing', - 'i', 'rp', 'del', 'code', 'strike', 'marquee', - 'q', 'rt', 'ins', 'font', 'strong', - 's', 'tt', 'kbd', 'mark', - 'u', 'xm', 'sub', 'nobr', - 'sup', 'ruby', - 'var', 'span', - 'wbr', 'time', - ); -} diff --git a/libs/php_idn/LICENSE b/libs/php_idn/LICENSE deleted file mode 100644 index 8000a6f..0000000 --- a/libs/php_idn/LICENSE +++ /dev/null @@ -1,504 +0,0 @@ - GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 - - Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - -[This is the first released version of the Lesser GPL. It also counts - as the successor of the GNU Library Public License, version 2, hence - the version number 2.1.] - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -Licenses are intended to guarantee your freedom to share and change -free software--to make sure the software is free for all its users. - - This license, the Lesser General Public License, applies to some -specially designated software packages--typically libraries--of the -Free Software Foundation and other authors who decide to use it. You -can use it too, but we suggest you first think carefully about whether -this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations below. - - When we speak of free software, we are referring to freedom of use, -not price. Our General Public Licenses are designed to make sure that -you have the freedom to distribute copies of free software (and charge -for this service if you wish); that you receive source code or can get -it if you want it; that you can change the software and use pieces of -it in new free programs; and that you are informed that you can do -these things. - - To protect your rights, we need to make restrictions that forbid -distributors to deny you these rights or to ask you to surrender these -rights. These restrictions translate to certain responsibilities for -you if you distribute copies of the library or if you modify it. - - For example, if you distribute copies of the library, whether gratis -or for a fee, you must give the recipients all the rights that we gave -you. You must make sure that they, too, receive or can get the source -code. If you link other code with the library, you must provide -complete object files to the recipients, so that they can relink them -with the library after making changes to the library and recompiling -it. And you must show them these terms so they know their rights. - - We protect your rights with a two-step method: (1) we copyright the -library, and (2) we offer you this license, which gives you legal -permission to copy, distribute and/or modify the library. - - To protect each distributor, we want to make it very clear that -there is no warranty for the free library. Also, if the library is -modified by someone else and passed on, the recipients should know -that what they have is not the original version, so that the original -author's reputation will not be affected by problems that might be -introduced by others. - - Finally, software patents pose a constant threat to the existence of -any free program. We wish to make sure that a company cannot -effectively restrict the users of a free program by obtaining a -restrictive license from a patent holder. Therefore, we insist that -any patent license obtained for a version of the library must be -consistent with the full freedom of use specified in this license. - - Most GNU software, including some libraries, is covered by the -ordinary GNU General Public License. This license, the GNU Lesser -General Public License, applies to certain designated libraries, and -is quite different from the ordinary General Public License. We use -this license for certain libraries in order to permit linking those -libraries into non-free programs. - - When a program is linked with a library, whether statically or using -a shared library, the combination of the two is legally speaking a -combined work, a derivative of the original library. The ordinary -General Public License therefore permits such linking only if the -entire combination fits its criteria of freedom. The Lesser General -Public License permits more lax criteria for linking other code with -the library. - - We call this license the "Lesser" General Public License because it -does Less to protect the user's freedom than the ordinary General -Public License. It also provides other free software developers Less -of an advantage over competing non-free programs. These disadvantages -are the reason we use the ordinary General Public License for many -libraries. However, the Lesser license provides advantages in certain -special circumstances. - - For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it becomes -a de-facto standard. To achieve this, non-free programs must be -allowed to use the library. A more frequent case is that a free -library does the same job as widely used non-free libraries. In this -case, there is little to gain by limiting the free library to free -software only, so we use the Lesser General Public License. - - In other cases, permission to use a particular library in non-free -programs enables a greater number of people to use a large body of -free software. For example, permission to use the GNU C Library in -non-free programs enables many more people to use the whole GNU -operating system, as well as its variant, the GNU/Linux operating -system. - - Although the Lesser General Public License is Less protective of the -users' freedom, it does ensure that the user of a program that is -linked with the Library has the freedom and the wherewithal to run -that program using a modified version of the Library. - - The precise terms and conditions for copying, distribution and -modification follow. Pay close attention to the difference between a -"work based on the library" and a "work that uses the library". The -former contains code derived from the library, whereas the latter must -be combined with the library in order to run. - - GNU LESSER GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License Agreement applies to any software library or other -program which contains a notice placed by the copyright holder or -other authorized party saying it may be distributed under the terms of -this Lesser General Public License (also called "this License"). -Each licensee is addressed as "you". - - A "library" means a collection of software functions and/or data -prepared so as to be conveniently linked with application programs -(which use some of those functions and data) to form executables. - - The "Library", below, refers to any such software library or work -which has been distributed under these terms. A "work based on the -Library" means either the Library or any derivative work under -copyright law: that is to say, a work containing the Library or a -portion of it, either verbatim or with modifications and/or translated -straightforwardly into another language. (Hereinafter, translation is -included without limitation in the term "modification".) - - "Source code" for a work means the preferred form of the work for -making modifications to it. For a library, complete source code means -all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control compilation -and installation of the library. - - Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running a program using the Library is not restricted, and output from -such a program is covered only if its contents constitute a work based -on the Library (independent of the use of the Library in a tool for -writing it). Whether that is true depends on what the Library does -and what the program that uses the Library does. - - 1. You may copy and distribute verbatim copies of the Library's -complete source code as you receive it, in any medium, provided that -you conspicuously and appropriately publish on each copy an -appropriate copyright notice and disclaimer of warranty; keep intact -all the notices that refer to this License and to the absence of any -warranty; and distribute a copy of this License along with the -Library. - - You may charge a fee for the physical act of transferring a copy, -and you may at your option offer warranty protection in exchange for a -fee. - - 2. You may modify your copy or copies of the Library or any portion -of it, thus forming a work based on the Library, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) The modified work must itself be a software library. - - b) You must cause the files modified to carry prominent notices - stating that you changed the files and the date of any change. - - c) You must cause the whole of the work to be licensed at no - charge to all third parties under the terms of this License. - - d) If a facility in the modified Library refers to a function or a - table of data to be supplied by an application program that uses - the facility, other than as an argument passed when the facility - is invoked, then you must make a good faith effort to ensure that, - in the event an application does not supply such function or - table, the facility still operates, and performs whatever part of - its purpose remains meaningful. - - (For example, a function in a library to compute square roots has - a purpose that is entirely well-defined independent of the - application. Therefore, Subsection 2d requires that any - application-supplied function or table used by this function must - be optional: if the application does not supply it, the square - root function must still compute square roots.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Library, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Library, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote -it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Library. - -In addition, mere aggregation of another work not based on the Library -with the Library (or with a work based on the Library) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may opt to apply the terms of the ordinary GNU General Public -License instead of this License to a given copy of the Library. To do -this, you must alter all the notices that refer to this License, so -that they refer to the ordinary GNU General Public License, version 2, -instead of to this License. (If a newer version than version 2 of the -ordinary GNU General Public License has appeared, then you can specify -that version instead if you wish.) Do not make any other change in -these notices. - - Once this change is made in a given copy, it is irreversible for -that copy, so the ordinary GNU General Public License applies to all -subsequent copies and derivative works made from that copy. - - This option is useful when you wish to copy part of the code of -the Library into a program that is not a library. - - 4. You may copy and distribute the Library (or a portion or -derivative of it, under Section 2) in object code or executable form -under the terms of Sections 1 and 2 above provided that you accompany -it with the complete corresponding machine-readable source code, which -must be distributed under the terms of Sections 1 and 2 above on a -medium customarily used for software interchange. - - If distribution of object code is made by offering access to copy -from a designated place, then offering equivalent access to copy the -source code from the same place satisfies the requirement to -distribute the source code, even though third parties are not -compelled to copy the source along with the object code. - - 5. A program that contains no derivative of any portion of the -Library, but is designed to work with the Library by being compiled or -linked with it, is called a "work that uses the Library". Such a -work, in isolation, is not a derivative work of the Library, and -therefore falls outside the scope of this License. - - However, linking a "work that uses the Library" with the Library -creates an executable that is a derivative of the Library (because it -contains portions of the Library), rather than a "work that uses the -library". The executable is therefore covered by this License. -Section 6 states terms for distribution of such executables. - - When a "work that uses the Library" uses material from a header file -that is part of the Library, the object code for the work may be a -derivative work of the Library even though the source code is not. -Whether this is true is especially significant if the work can be -linked without the Library, or if the work is itself a library. The -threshold for this to be true is not precisely defined by law. - - If such an object file uses only numerical parameters, data -structure layouts and accessors, and small macros and small inline -functions (ten lines or less in length), then the use of the object -file is unrestricted, regardless of whether it is legally a derivative -work. (Executables containing this object code plus portions of the -Library will still fall under Section 6.) - - Otherwise, if the work is a derivative of the Library, you may -distribute the object code for the work under the terms of Section 6. -Any executables containing that work also fall under Section 6, -whether or not they are linked directly with the Library itself. - - 6. As an exception to the Sections above, you may also combine or -link a "work that uses the Library" with the Library to produce a -work containing portions of the Library, and distribute that work -under terms of your choice, provided that the terms permit -modification of the work for the customer's own use and reverse -engineering for debugging such modifications. - - You must give prominent notice with each copy of the work that the -Library is used in it and that the Library and its use are covered by -this License. You must supply a copy of this License. If the work -during execution displays copyright notices, you must include the -copyright notice for the Library among them, as well as a reference -directing the user to the copy of this License. Also, you must do one -of these things: - - a) Accompany the work with the complete corresponding - machine-readable source code for the Library including whatever - changes were used in the work (which must be distributed under - Sections 1 and 2 above); and, if the work is an executable linked - with the Library, with the complete machine-readable "work that - uses the Library", as object code and/or source code, so that the - user can modify the Library and then relink to produce a modified - executable containing the modified Library. (It is understood - that the user who changes the contents of definitions files in the - Library will not necessarily be able to recompile the application - to use the modified definitions.) - - b) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (1) uses at run time a - copy of the library already present on the user's computer system, - rather than copying library functions into the executable, and (2) - will operate properly with a modified version of the library, if - the user installs one, as long as the modified version is - interface-compatible with the version that the work was made with. - - c) Accompany the work with a written offer, valid for at - least three years, to give the same user the materials - specified in Subsection 6a, above, for a charge no more - than the cost of performing this distribution. - - d) If distribution of the work is made by offering access to copy - from a designated place, offer equivalent access to copy the above - specified materials from the same place. - - e) Verify that the user has already received a copy of these - materials or that you have already sent this user a copy. - - For an executable, the required form of the "work that uses the -Library" must include any data and utility programs needed for -reproducing the executable from it. However, as a special exception, -the materials to be distributed need not include anything that is -normally distributed (in either source or binary form) with the major -components (compiler, kernel, and so on) of the operating system on -which the executable runs, unless that component itself accompanies -the executable. - - It may happen that this requirement contradicts the license -restrictions of other proprietary libraries that do not normally -accompany the operating system. Such a contradiction means you cannot -use both them and the Library together in an executable that you -distribute. - - 7. You may place library facilities that are a work based on the -Library side-by-side in a single library together with other library -facilities not covered by this License, and distribute such a combined -library, provided that the separate distribution of the work based on -the Library and of the other library facilities is otherwise -permitted, and provided that you do these two things: - - a) Accompany the combined library with a copy of the same work - based on the Library, uncombined with any other library - facilities. This must be distributed under the terms of the - Sections above. - - b) Give prominent notice with the combined library of the fact - that part of it is a work based on the Library, and explaining - where to find the accompanying uncombined form of the same work. - - 8. You may not copy, modify, sublicense, link with, or distribute -the Library except as expressly provided under this License. Any -attempt otherwise to copy, modify, sublicense, link with, or -distribute the Library is void, and will automatically terminate your -rights under this License. However, parties who have received copies, -or rights, from you under this License will not have their licenses -terminated so long as such parties remain in full compliance. - - 9. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Library or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Library (or any work based on the -Library), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Library or works based on it. - - 10. Each time you redistribute the Library (or any work based on the -Library), the recipient automatically receives a license from the -original licensor to copy, distribute, link with or modify the Library -subject to these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties with -this License. - - 11. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Library at all. For example, if a patent -license would not permit royalty-free redistribution of the Library by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Library. - -If any portion of this section is held invalid or unenforceable under any -particular circumstance, the balance of the section is intended to apply, -and the section as a whole is intended to apply in other circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 12. If the distribution and/or use of the Library is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License may add -an explicit geographical distribution limitation excluding those countries, -so that distribution is permitted only in or among countries not thus -excluded. In such case, this License incorporates the limitation as if -written in the body of this License. - - 13. The Free Software Foundation may publish revised and/or new -versions of the Lesser General Public License from time to time. -Such new versions will be similar in spirit to the present version, -but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Library -specifies a version number of this License which applies to it and -"any later version", you have the option of following the terms and -conditions either of that version or of any later version published by -the Free Software Foundation. If the Library does not specify a -license version number, you may choose any version ever published by -the Free Software Foundation. - - 14. If you wish to incorporate parts of the Library into other free -programs whose distribution conditions are incompatible with these, -write to the author to ask for permission. For software which is -copyrighted by the Free Software Foundation, write to the Free -Software Foundation; we sometimes make exceptions for this. Our -decision will be guided by the two goals of preserving the free status -of all derivatives of our free software and of promoting the sharing -and reuse of software generally. - - NO WARRANTY - - 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Libraries - - If you develop a new library, and you want it to be of the greatest -possible use to the public, we recommend making it free software that -everyone can redistribute and change. You can do so by permitting -redistribution under these terms (or, alternatively, under the terms of the -ordinary General Public License). - - To apply these terms, attach the following notices to the library. It is -safest to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least the -"copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 - USA - -Also add information on how to contact you by electronic and paper mail. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the library, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the - library `Frob' (a library for tweaking knobs) written by James Random - Hacker. - - , 1 April 1990 - Ty Coon, President of Vice - -That's all there is to it! diff --git a/libs/php_idn/README.md b/libs/php_idn/README.md deleted file mode 100644 index d1d368e..0000000 --- a/libs/php_idn/README.md +++ /dev/null @@ -1,31 +0,0 @@ -PHP IDN Punycode -================ - -Encode and decode IDN Punycode if not exists internal php functions `idn_to_ascii` and `idn_to_utf8`. -Functions use algorithm by rfc 3492. - -[![Build Status](https://travis-ci.org/IgorVBelousov/php_idn.svg?branch=master)](https://travis-ci.org/IgorVBelousov/php_idn) - -**function EncodePunycodeIDN( $value )** string - -Encode UTF-8 domain name to IDN Punycode - -Parameters: - -string **$value** Domain name - -Returns: - -Encoded Domain name - -**function DecodePunycodeIDN( $value )** string - -Decode IDN Punycode to UTF-8 domain name - -Parameters: - -string **$value** Punycode - -Returns: - -Domain name in UTF-8 charset \ No newline at end of file diff --git a/libs/php_idn/idna.php b/libs/php_idn/idna.php deleted file mode 100644 index bac2b63..0000000 --- a/libs/php_idn/idna.php +++ /dev/null @@ -1,320 +0,0 @@ - - * @copyright 2008 Nicolas Thouvenin - * @license http://opensource.org/licenses/LGPL-2.1 LGPL v2.1 - */ -function ordUTF8($c, $index = 0, &$bytes = null) - { - $len = strlen($c); - $bytes = 0; - if ($index >= $len) - return false; - $h = ord($c{$index}); - if ($h <= 0x7F) { - $bytes = 1; - return $h; - } - else if ($h < 0xC2) - return false; - else if ($h <= 0xDF && $index < $len - 1) { - $bytes = 2; - return ($h & 0x1F) << 6 | (ord($c{$index + 1}) & 0x3F); - } - else if ($h <= 0xEF && $index < $len - 2) { - $bytes = 3; - return ($h & 0x0F) << 12 | (ord($c{$index + 1}) & 0x3F) << 6 - | (ord($c{$index + 2}) & 0x3F); - } - else if ($h <= 0xF4 && $index < $len - 3) { - $bytes = 4; - return ($h & 0x0F) << 18 | (ord($c{$index + 1}) & 0x3F) << 12 - | (ord($c{$index + 2}) & 0x3F) << 6 - | (ord($c{$index + 3}) & 0x3F); - } - else - return false; - } - -/** - * Encode UTF-8 domain name to IDN Punycode - * - * @param string $value Domain name - * @return string Encoded Domain name - * - * @author Igor V Belousov - * @copyright 2013, 2015 Igor V Belousov - * @license http://opensource.org/licenses/LGPL-2.1 LGPL v2.1 - * @link http://belousovv.ru/myscript/phpIDN - */ -function EncodePunycodeIDN( $value ) - { - if ( function_exists( 'idn_to_ascii' ) ) { - return idn_to_ascii( $value ); - } - - /* search subdomains */ - $sub_domain = explode( '.', $value ); - if ( count( $sub_domain ) > 1 ) { - $sub_result = ''; - foreach ( $sub_domain as $sub_value ) { - $sub_result .= '.' . EncodePunycodeIDN( $sub_value ); - } - return substr( $sub_result, 1 ); - } - - /* http://tools.ietf.org/html/rfc3492#section-6.3 */ - $n = 0x80; - $delta = 0; - $bias = 72; - $output = array(); - - $input = array(); - $str = $value; - while ( mb_strlen( $str , 'UTF-8' ) > 0 ) - { - array_push( $input, mb_substr( $str, 0, 1, 'UTF-8' ) ); - $str = (version_compare(PHP_VERSION, '5.4.8','<'))?mb_substr( $str, 1, mb_strlen($str, 'UTF-8') , 'UTF-8' ):mb_substr( $str, 1, null, 'UTF-8' ); - } - - /* basic symbols */ - $basic = preg_grep( '/[\x00-\x7f]/', $input ); - $b = $basic; - - if ( $b == $input ) - { - return $value; - } - $b = count( $b ); - if ( $b > 0 ) { - $output = $basic; - /* add delimeter */ - $output[] = '-'; - } - unset($basic); - /* add prefix */ - array_unshift( $output, 'xn--' ); - - $input_len = count( $input ); - $h = $b; - - $ord_input = array(); - - while ( $h < $input_len ) { - $m = 0x10FFFF; - for ( $i = 0; $i < $input_len; ++$i ) - { - $ord_input[ $i ] = ordUtf8( $input[ $i ] ); - if ( ( $ord_input[ $i ] >= $n ) && ( $ord_input[ $i ] < $m ) ) - { - $m = $ord_input[ $i ]; - } - } - if ( ( $m - $n ) > ( 0x10FFFF / ( $h + 1 ) ) ) - { - return $value; - } - $delta += ( $m - $n ) * ( $h + 1 ); - $n = $m; - - for ( $i = 0; $i < $input_len; ++$i ) - { - $c = $ord_input[ $i ]; - if ( $c < $n ) - { - ++$delta; - if ( $delta == 0 ) - { - return $value; - } - } - if ( $c == $n ) - { - $q = $delta; - for ( $k = 36;; $k += 36 ) - { - if ( $k <= $bias ) - { - $t = 1; - } - elseif ( $k >= ( $bias + 26 ) ) - { - $t = 26; - } - else - { - $t = $k - $bias; - } - if ( $q < $t ) - { - break; - } - $tmp_int = $t + ( $q - $t ) % ( 36 - $t ); - $output[] = chr( ( $tmp_int + 22 + 75 * ( $tmp_int < 26 ) ) ); - $q = ( $q - $t ) / ( 36 - $t ); - } - - $output[] = chr( ( $q + 22 + 75 * ( $q < 26 ) ) ); - /* http://tools.ietf.org/html/rfc3492#section-6.1 */ - $delta = ( $h == $b ) ? $delta / 700 : $delta>>1; - - $delta += intval( $delta / ( $h + 1 ) ); - - $k2 = 0; - while ( $delta > 455 ) - { - $delta /= 35; - $k2 += 36; - } - $bias = intval( $k2 + 36 * $delta / ( $delta + 38 ) ); - /* end section-6.1 */ - $delta = 0; - ++$h; - } - } - ++$delta; - ++$n; - } - return implode( '', $output ); - } - -/** - * Decode IDN Punycode to UTF-8 domain name - * - * @param string $value Punycode - * @return string Domain name in UTF-8 charset - * - * @author Igor V Belousov - * @copyright 2013, 2015 Igor V Belousov - * @license http://opensource.org/licenses/LGPL-2.1 LGPL v2.1 - * @link http://belousovv.ru/myscript/phpIDN - */ -function DecodePunycodeIDN( $value ) - { - if ( function_exists( 'idn_to_utf8' ) ) { - return idn_to_utf8( $value ); - } - - /* search subdomains */ - $sub_domain = explode( '.', $value ); - if ( count( $sub_domain ) > 1 ) { - $sub_result = ''; - foreach ( $sub_domain as $sub_value ) { - $sub_result .= '.' . DecodePunycodeIDN( $sub_value ); - } - return substr( $sub_result, 1 ); - } - - /* search prefix */ - if ( substr( $value, 0, 4 ) != 'xn--' ) - { - return $value; - } - else - { - $bad_input = $value; - $value = substr( $value, 4 ); - } - - $n = 0x80; - $i = 0; - $bias = 72; - $output = array(); - - /* search delimeter */ - $d = strrpos( $value, '-' ); - - if ( $d > 0 ) { - for ( $j = 0; $j < $d; ++$j) { - $c = $value[ $j ]; - $output[] = $c; - if ( $c > 0x7F ) - { - return $bad_input; - } - } - ++$d; - } else { - $d = 0; - } - - while ($d < strlen( $value ) ) - { - $old_i = $i; - $w = 1; - - for ($k = 36;; $k += 36) - { - if ( $d == strlen( $value ) ) - { - return $bad_input; - } - $c = $value[ $d++ ]; - $c = ord( $c ); - - $digit = ( $c - 48 < 10 ) ? $c - 22 : - ( - ( $c - 65 < 26 ) ? $c - 65 : - ( - ( $c - 97 < 26 ) ? $c - 97 : 36 - ) - ); - if ( $digit > ( 0x10FFFF - $i ) / $w ) - { - return $bad_input; - } - $i += $digit * $w; - - if ( $k <= $bias ) - { - $t = 1; - } - elseif ( $k >= $bias + 26 ) - { - $t = 26; - } - else - { - $t = $k - $bias; - } - if ( $digit < $t ) { - break; - } - - $w *= 36 - $t; - - } - - $delta = $i - $old_i; - - /* http://tools.ietf.org/html/rfc3492#section-6.1 */ - $delta = ( $old_i == 0 ) ? $delta/700 : $delta>>1; - - $count_output_plus_one = count( $output ) + 1; - $delta += intval( $delta / $count_output_plus_one ); - - $k2 = 0; - while ( $delta > 455 ) - { - $delta /= 35; - $k2 += 36; - } - $bias = intval( $k2 + 36 * $delta / ( $delta + 38 ) ); - /* end section-6.1 */ - if ( $i / $count_output_plus_one > 0x10FFFF - $n ) - { - return $bad_input; - } - $n += intval( $i / $count_output_plus_one ); - $i %= $count_output_plus_one; - array_splice( $output, $i, 0, - html_entity_decode( '&#' . $n . ';', ENT_NOQUOTES, 'UTF-8' ) - ); - ++$i; - } - - return implode( '', $output ); - } - diff --git a/libs/templates/email_status_update.html b/libs/templates/email_status_update.html deleted file mode 100644 index dea833e..0000000 --- a/libs/templates/email_status_update.html +++ /dev/null @@ -1,56 +0,0 @@ - - - - - - - - - -

        %service_status_update_from% %name%

        -
        - - - - - - - - - - - - - - - - - - - -
        %services_impacted%:%service%
        %status_label%:%status%
        %time_label%:%time%
         %comment%
        -
        - - - - - - -
        -

        %unsubscribe%

        -

         %powered_by% Server-Status

        \ No newline at end of file diff --git a/locale/cs_CZ/jquery.timeago.js b/locale/cs_CZ/jquery.timeago.js deleted file mode 100644 index b940f69..0000000 --- a/locale/cs_CZ/jquery.timeago.js +++ /dev/null @@ -1,34 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Czech - (function() { - function f(n, d, a) { - return a[d>=0 ? 0 : a.length===2 || n<5 ? 1 : 2]; - } - - jQuery.timeago.settings.strings = { - prefixAgo: 'před', - prefixFromNow: 'za', - suffixAgo: null, - suffixFromNow: null, - seconds: function(n, d) {return f(n, d, ['méně než minutou', 'méně než minutu']);}, - minute: function(n, d) {return f(n, d, ['minutou', 'minutu']);}, - minutes: function(n, d) {return f(n, d, ['%d minutami', '%d minuty', '%d minut']);}, - hour: function(n, d) {return f(n, d, ['hodinou', 'hodinu']);}, - hours: function(n, d) {return f(n, d, ['%d hodinami', '%d hodiny', '%d hodin']);}, - day: function(n, d) {return f(n, d, ['%d dnem', '%d den']);}, - days: function(n, d) {return f(n, d, ['%d dny', '%d dny', '%d dní']);}, - month: function(n, d) {return f(n, d, ['%d měsícem', '%d měsíc']);}, - months: function(n, d) {return f(n, d, ['%d měsíci', '%d měsíce', '%d měsíců']);}, - year: function(n, d) {return f(n, d, ['%d rokem', '%d rok']);}, - years: function(n, d) {return f(n, d, ['%d lety', '%d roky', '%d let']);} - }; - })(); -})); diff --git a/locale/da_DK/jquery.timeago.js b/locale/da_DK/jquery.timeago.js deleted file mode 100644 index 236c34c..0000000 --- a/locale/da_DK/jquery.timeago.js +++ /dev/null @@ -1,28 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Danish - jQuery.timeago.settings.strings = { - prefixAgo: "for", - prefixFromNow: "om", - suffixAgo: "siden", - suffixFromNow: "", - seconds: "mindre end et minut", - minute: "ca. et minut", - minutes: "%d minutter", - hour: "ca. en time", - hours: "ca. %d timer", - day: "en dag", - days: "%d dage", - month: "ca. en måned", - months: "%d måneder", - year: "ca. et år", - years: "%d år" - }; -})); diff --git a/locale/de_DE/jquery.timeago.js b/locale/de_DE/jquery.timeago.js deleted file mode 100644 index 6a877a2..0000000 --- a/locale/de_DE/jquery.timeago.js +++ /dev/null @@ -1,28 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // German - jQuery.timeago.settings.strings = { - prefixAgo: "vor", - prefixFromNow: "in", - suffixAgo: "", - suffixFromNow: "", - seconds: "wenigen Sekunden", - minute: "etwa einer Minute", - minutes: "%d Minuten", - hour: "etwa einer Stunde", - hours: "%d Stunden", - day: "etwa einem Tag", - days: "%d Tagen", - month: "etwa einem Monat", - months: "%d Monaten", - year: "etwa einem Jahr", - years: "%d Jahren" - }; -})); diff --git a/locale/en_GB/jquery.timeago.js b/locale/en_GB/jquery.timeago.js deleted file mode 100644 index 8ca50af..0000000 --- a/locale/en_GB/jquery.timeago.js +++ /dev/null @@ -1,30 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // English (Template) - jQuery.timeago.settings.strings = { - prefixAgo: null, - prefixFromNow: null, - suffixAgo: "ago", - suffixFromNow: "from now", - seconds: "less than a minute", - minute: "about a minute", - minutes: "%d minutes", - hour: "about an hour", - hours: "about %d hours", - day: "a day", - days: "%d days", - month: "about a month", - months: "%d months", - year: "about a year", - years: "%d years", - wordSeparator: " ", - numbers: [] - }; -})); diff --git a/locale/es_ES/jquery.timeago.js b/locale/es_ES/jquery.timeago.js deleted file mode 100644 index 0785b3f..0000000 --- a/locale/es_ES/jquery.timeago.js +++ /dev/null @@ -1,29 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Spanish - jQuery.timeago.settings.strings = { - prefixAgo: "hace", - prefixFromNow: "dentro de", - suffixAgo: "", - suffixFromNow: "", - seconds: "menos de un minuto", - minute: "un minuto", - minutes: "unos %d minutos", - hour: "una hora", - hours: "%d horas", - day: "un día", - days: "%d días", - month: "un mes", - months: "%d meses", - year: "un año", - years: "%d años" - }; -})); - diff --git a/locale/fr_FR/jquery.timeago.js b/locale/fr_FR/jquery.timeago.js deleted file mode 100644 index 1bb052a..0000000 --- a/locale/fr_FR/jquery.timeago.js +++ /dev/null @@ -1,27 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // French - jQuery.timeago.settings.strings = { - // environ ~= about, it's optional - prefixAgo: "il y a", - prefixFromNow: "d'ici", - seconds: "moins d'une minute", - minute: "environ une minute", - minutes: "environ %d minutes", - hour: "environ une heure", - hours: "environ %d heures", - day: "environ un jour", - days: "environ %d jours", - month: "environ un mois", - months: "environ %d mois", - year: "un an", - years: "%d ans" - }; -})); diff --git a/locale/it_IT/jquery.timeago.js b/locale/it_IT/jquery.timeago.js deleted file mode 100644 index e1cac84..0000000 --- a/locale/it_IT/jquery.timeago.js +++ /dev/null @@ -1,26 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Italian - jQuery.timeago.settings.strings = { - suffixAgo: "fa", - suffixFromNow: "da ora", - seconds: "meno di un minuto", - minute: "circa un minuto", - minutes: "%d minuti", - hour: "circa un'ora", - hours: "circa %d ore", - day: "un giorno", - days: "%d giorni", - month: "circa un mese", - months: "%d mesi", - year: "circa un anno", - years: "%d anni" - }; -})); diff --git a/locale/lt_LT/jquery.timeago.js b/locale/lt_LT/jquery.timeago.js deleted file mode 100644 index 2079fcc..0000000 --- a/locale/lt_LT/jquery.timeago.js +++ /dev/null @@ -1,30 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - //Lithuanian - jQuery.timeago.settings.strings = { - prefixAgo: "prieš", - prefixFromNow: null, - suffixAgo: null, - suffixFromNow: "nuo dabar", - seconds: "%d sek.", - minute: "min.", - minutes: "%d min.", - hour: "val.", - hours: "%d val.", - day: "1 d.", - days: "%d d.", - month: "mėn.", - months: "%d mėn.", - year: "metus", - years: "%d metus", - wordSeparator: " ", - numbers: [] - }; -})); diff --git a/locale/nb_NO/jquery.timeago.js b/locale/nb_NO/jquery.timeago.js deleted file mode 100644 index d6d7667..0000000 --- a/locale/nb_NO/jquery.timeago.js +++ /dev/null @@ -1,30 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Norsk - jQuery.timeago.settings.strings = { - prefixAgo: null, - prefixFromNow: null, - suffixAgo: "siden", - suffixFromNow: "fra nå", - seconds: "mindre en ett minutt", - minute: "ca ett minutt", - minutes: "%d minutter", - hour: "ca en time", - hours: "ca %d timer", - day: "en dag", - days: "%d dager", - month: "ca en måned", - months: "%d måneder", - year: "ca ett år", - years: "%d år", - wordSeparator: " ", - numbers: [] - }; -})); diff --git a/locale/nl_NL/jquery.timeago.js b/locale/nl_NL/jquery.timeago.js deleted file mode 100644 index 2c5de89..0000000 --- a/locale/nl_NL/jquery.timeago.js +++ /dev/null @@ -1,30 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Dutch - jQuery.timeago.settings.strings = { - prefixAgo: null, - prefixFromNow: "over", - suffixAgo: "geleden", - suffixFromNow: null, - seconds: "minder dan een minuut", - minute: "ongeveer een minuut", - minutes: "%d minuten", - hour: "ongeveer een uur", - hours: "ongeveer %d uur", - day: "een dag", - days: "%d dagen", - month: "ongeveer een maand", - months: "%d maanden", - year: "ongeveer een jaar", - years: "%d jaar", - wordSeparator: " ", - numbers: [] - }; -})); diff --git a/locale/pl_PL/jquery.timeago.js b/locale/pl_PL/jquery.timeago.js deleted file mode 100644 index 4842784..0000000 --- a/locale/pl_PL/jquery.timeago.js +++ /dev/null @@ -1,39 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Polish - function numpf(n, s, t) { - // s - 2-4, 22-24, 32-34 ... - // t - 5-21, 25-31, ... - var n10 = n % 10; - if ( (n10 > 1) && (n10 < 5) && ( (n > 20) || (n < 10) ) ) { - return s; - } else { - return t; - } - } - - jQuery.timeago.settings.strings = { - prefixAgo: null, - prefixFromNow: "za", - suffixAgo: "temu", - suffixFromNow: null, - seconds: "mniej niż minutę", - minute: "minutę", - minutes: function(value) { return numpf(value, "%d minuty", "%d minut"); }, - hour: "godzinę", - hours: function(value) { return numpf(value, "%d godziny", "%d godzin"); }, - day: "dzień", - days: "%d dni", - month: "miesiąc", - months: function(value) { return numpf(value, "%d miesiące", "%d miesięcy"); }, - year: "rok", - years: function(value) { return numpf(value, "%d lata", "%d lat"); } - }; -})); diff --git a/locale/pt_BR/jquery.timeago.js b/locale/pt_BR/jquery.timeago.js deleted file mode 100644 index a8701a8..0000000 --- a/locale/pt_BR/jquery.timeago.js +++ /dev/null @@ -1,28 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Brazilian Portuguese - jQuery.timeago.settings.strings = { - prefixAgo: "há", - prefixFromNow: "em", - suffixAgo: null, - suffixFromNow: null, - seconds: "alguns segundos", - minute: "um minuto", - minutes: "%d minutos", - hour: "uma hora", - hours: "%d horas", - day: "um dia", - days: "%d dias", - month: "um mês", - months: "%d meses", - year: "um ano", - years: "%d anos" - }; -})); diff --git a/locale/sk_SK/jquery.timeago.js b/locale/sk_SK/jquery.timeago.js deleted file mode 100644 index e28ab7c..0000000 --- a/locale/sk_SK/jquery.timeago.js +++ /dev/null @@ -1,34 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Slovak - (function() { - function f(n, d, a) { - return a[d>=0 ? 0 : a.length===2 || n<5 ? 1 : 2]; - } - - jQuery.timeago.settings.strings = { - prefixAgo: 'pred', - prefixFromNow: 'o', - suffixAgo: null, - suffixFromNow: null, - seconds: function(n, d) {return f(n, d, ['menej ako minútou', 'menej ako minútu']);}, - minute: function(n, d) {return f(n, d, ['minútou', 'minútu']);}, - minutes: function(n, d) {return f(n, d, ['%d minútami', '%d minúty', '%d minút']);}, - hour: function(n, d) {return f(n, d, ['hodinou', 'hodinu']);}, - hours: function(n, d) {return f(n, d, ['%d hodinami', '%d hodiny', '%d hodín']);}, - day: function(n, d) {return f(n, d, ['%d dňom', '%d deň']);}, - days: function(n, d) {return f(n, d, ['%d dňami', '%d dni', '%d dní']);}, - month: function(n, d) {return f(n, d, ['%d mesiacom', '%d mesiac']);}, - months: function(n, d) {return f(n, d, ['%d mesiacmi', '%d mesiace', '%d mesiacov']);}, - year: function(n, d) {return f(n, d, ['%d rokom', '%d rok']);}, - years: function(n, d) {return f(n, d, ['%d rokmi', '%d roky', '%d rokov']);} - }; - })(); -})); diff --git a/locale/sr_RS/jquery.timeago.js b/locale/sr_RS/jquery.timeago.js deleted file mode 100644 index bd1efe7..0000000 --- a/locale/sr_RS/jquery.timeago.js +++ /dev/null @@ -1,54 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Serbian - var numpf = function (n, f, s, t) { - var n10; - n10 = n % 10; - if (n10 === 1 && (n === 1 || n > 20)) { - return f; - } else if (n10 > 1 && n10 < 5 && (n > 20 || n < 10)) { - return s; - } else { - return t; - } - }; - - jQuery.timeago.settings.strings = { - prefixAgo: "пре", - prefixFromNow: "за", - suffixAgo: null, - suffixFromNow: null, - second: "секунд", - seconds: function (value) { - return numpf(value, "%d секунд", "%d секунде", "%d секунди"); - }, - minute: "један минут", - minutes: function (value) { - return numpf(value, "%d минут", "%d минута", "%d минута"); - }, - hour: "један сат", - hours: function (value) { - return numpf(value, "%d сат", "%d сата", "%d сати"); - }, - day: "један дан", - days: function (value) { - return numpf(value, "%d дан", "%d дана", "%d дана"); - }, - month: "месец дана", - months: function (value) { - return numpf(value, "%d месец", "%d месеца", "%d месеци"); - }, - year: "годину дана", - years: function (value) { - return numpf(value, "%d годину", "%d године", "%d година"); - }, - wordSeparator: " " - }; -})); diff --git a/locale/tr_TR/jquery.timeago.js b/locale/tr_TR/jquery.timeago.js deleted file mode 100644 index 8e0d2d4..0000000 --- a/locale/tr_TR/jquery.timeago.js +++ /dev/null @@ -1,26 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Turkish - jQuery.timeago.settings.strings = { - suffixAgo: 'önce', - suffixFromNow: null, - seconds: 'birkaç saniye', - minute: '1 dakika', - minutes: '%d dakika', - hour: '1 saat', - hours: '%d saat', - day: '1 gün', - days: '%d gün', - month: '1 ay', - months: '%d ay', - year: '1 yıl', - years: '%d yıl' - }; -})); diff --git a/locale/uk_UA/jquery.timeago.js b/locale/uk_UA/jquery.timeago.js deleted file mode 100644 index 489963b..0000000 --- a/locale/uk_UA/jquery.timeago.js +++ /dev/null @@ -1,42 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Ukrainian - function numpf(n, f, s, t) { - // f - 1, 21, 31, ... - // s - 2-4, 22-24, 32-34 ... - // t - 5-20, 25-30, ... - var n10 = n % 10; - if ( (n10 === 1) && ( (n === 1) || (n > 20) ) ) { - return f; - } else if ( (n10 > 1) && (n10 < 5) && ( (n > 20) || (n < 10) ) ) { - return s; - } else { - return t; - } - } - - jQuery.timeago.settings.strings = { - prefixAgo: null, - prefixFromNow: "через", - suffixAgo: "тому", - suffixFromNow: null, - seconds: "менше хвилини", - minute: "хвилина", - minutes: function(value) { return numpf(value, "%d хвилина", "%d хвилини", "%d хвилин"); }, - hour: "година", - hours: function(value) { return numpf(value, "%d година", "%d години", "%d годин"); }, - day: "день", - days: function(value) { return numpf(value, "%d день", "%d дні", "%d днів"); }, - month: "місяць", - months: function(value) { return numpf(value, "%d місяць", "%d місяці", "%d місяців"); }, - year: "рік", - years: function(value) { return numpf(value, "%d рік", "%d роки", "%d років"); } - }; -})); diff --git a/locale/zh_CN/jquery.timeago.js b/locale/zh_CN/jquery.timeago.js deleted file mode 100644 index c672fb7..0000000 --- a/locale/zh_CN/jquery.timeago.js +++ /dev/null @@ -1,31 +0,0 @@ -(function (factory) { - if (typeof define === 'function' && define.amd) { - define(['jquery'], factory); - } else if (typeof module === 'object' && typeof module.exports === 'object') { - factory(require('jquery')); - } else { - factory(jQuery); - } -}(function (jQuery) { - // Simplified Chinese - jQuery.timeago.settings.strings = { - prefixAgo: null, - prefixFromNow: "从现在开始", - suffixAgo: "之前", - suffixFromNow: null, - seconds: "不到1分钟", - minute: "大约1分钟", - minutes: "%d分钟", - hour: "大约1小时", - hours: "大约%d小时", - day: "1天", - days: "%d天", - month: "大约1个月", - months: "%d月", - year: "大约1年", - years: "%d年", - numbers: [], - wordSeparator: "" - }; -})); - diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 0000000..9ef7829 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,312 @@ +{ + "name": "server-status", + "lockfileVersion": 2, + "requires": true, + "packages": { + "": { + "dependencies": { + "sass": "^1.42.1" + } + }, + "node_modules/anymatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.2.tgz", + "integrity": "sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==", + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/binary-extensions": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", + "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", + "engines": { + "node": ">=8" + } + }, + "node_modules/braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "dependencies": { + "fill-range": "^7.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/chokidar": { + "version": "3.5.2", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.2.tgz", + "integrity": "sha512-ekGhOnNVPgT77r4K/U3GDhu+FQ2S8TnK/s2KbIGXi0SZWuwkZ2QNyfWdZW+TVfn84DpEP7rLeCt2UI6bJ8GwbQ==", + "dependencies": { + "anymatch": "~3.1.2", + "braces": "~3.0.2", + "glob-parent": "~5.1.2", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.6.0" + }, + "engines": { + "node": ">= 8.10.0" + }, + "optionalDependencies": { + "fsevents": "~2.3.2" + } + }, + "node_modules/fill-range": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/fsevents": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", + "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/glob-parent": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dependencies": { + "binary-extensions": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-glob": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", + "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", + "dependencies": { + "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/picomatch": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.0.tgz", + "integrity": "sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw==", + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/readdirp": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", + "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", + "dependencies": { + "picomatch": "^2.2.1" + }, + "engines": { + "node": ">=8.10.0" + } + }, + "node_modules/sass": { + "version": "1.42.1", + "resolved": "https://registry.npmjs.org/sass/-/sass-1.42.1.tgz", + "integrity": "sha512-/zvGoN8B7dspKc5mC6HlaygyCBRvnyzzgD5khiaCfglWztY99cYoiTUksVx11NlnemrcfH5CEaCpsUKoW0cQqg==", + "dependencies": { + "chokidar": ">=3.0.0 <4.0.0" + }, + "bin": { + "sass": "sass.js" + }, + "engines": { + "node": ">=8.9.0" + } + }, + "node_modules/to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + } + }, + "dependencies": { + "anymatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.2.tgz", + "integrity": "sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==", + "requires": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + } + }, + "binary-extensions": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", + "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==" + }, + "braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "requires": { + "fill-range": "^7.0.1" + } + }, + "chokidar": { + "version": "3.5.2", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.2.tgz", + "integrity": "sha512-ekGhOnNVPgT77r4K/U3GDhu+FQ2S8TnK/s2KbIGXi0SZWuwkZ2QNyfWdZW+TVfn84DpEP7rLeCt2UI6bJ8GwbQ==", + "requires": { + "anymatch": "~3.1.2", + "braces": "~3.0.2", + "fsevents": "~2.3.2", + "glob-parent": "~5.1.2", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.6.0" + } + }, + "fill-range": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", + "requires": { + "to-regex-range": "^5.0.1" + } + }, + "fsevents": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", + "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", + "optional": true + }, + "glob-parent": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "requires": { + "is-glob": "^4.0.1" + } + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "requires": { + "binary-extensions": "^2.0.0" + } + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=" + }, + "is-glob": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", + "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" + }, + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==" + }, + "picomatch": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.0.tgz", + "integrity": "sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw==" + }, + "readdirp": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", + "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", + "requires": { + "picomatch": "^2.2.1" + } + }, + "sass": { + "version": "1.42.1", + "resolved": "https://registry.npmjs.org/sass/-/sass-1.42.1.tgz", + "integrity": "sha512-/zvGoN8B7dspKc5mC6HlaygyCBRvnyzzgD5khiaCfglWztY99cYoiTUksVx11NlnemrcfH5CEaCpsUKoW0cQqg==", + "requires": { + "chokidar": ">=3.0.0 <4.0.0" + } + }, + "to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "requires": { + "is-number": "^7.0.0" + } + } + } +} diff --git a/package.json b/package.json new file mode 100644 index 0000000..3a84912 --- /dev/null +++ b/package.json @@ -0,0 +1,9 @@ +{ + "dependencies": { + "sass": "^1.42.1" + }, + "scripts": { + "sass": "sass src/css/main.scss --style compressed --no-source-map > src/css/main.css", + "convert": "sass-convert src/css/main.sass src/css/main2.scss" + } +} diff --git a/policy.php b/policy.php deleted file mode 100644 index 9379583..0000000 --- a/policy.php +++ /dev/null @@ -1,48 +0,0 @@ -" . _("Privacy Policy") . ""; - echo "

        " . _("Who we are") . "

        "; - echo WHO_WE_ARE; - echo "

        " . _("Contact") . "

        "; - echo POLICY_NAME . "
        "; - echo ADDRESS . "
        "; - echo POLICY_MAIL . "
        "; - if(defined('POLICY_PHONE') && POLICY_PHONE != ""){ - echo POLICY_PHONE . "
        "; - } - - echo '

        ' . _("What personal data we collect and why") . '

        '; - echo '

        ' . _("General") . "

        "; - echo _("If you access our websites, the following information will be saved: IP-address, Date, Time, Browser queries, - General information about your browser, operating system and all search queries on the sites. - This user data will be used for anonym user statistics to recognize trends and improve our content. - ") . "
        "; - echo '

        ' . _("Telegram") . "

        "; - echo _("If you use the Telegram Login Widget (The blue \"Login with Telegram\" button), we recive the following data from the service \"Telegram\" (telegram.org):"); - echo '
          -
        • ' . _("Your Telegram-User-ID") . "
        • -
        • " . _("Your Telegram username") . '
        • -
        • ' . _("The name you provided when registering with Telegram.") . '
        • -
        • ' . _("Your telegram profile picture") . '
        • -
        '; - echo _("Although we are receiving this data, we only save your telegram ID, your telegram username and the first and last name you provided telegram when registred for their service."); - echo _("We are saving this data, to provide a subscription service which alerts you about status update via our telegram bot. With this data we know who we need to send the alert to. Also we know your name, so we can say hi to you."); - echo _("Because of this, we also save who has subscribed which service."); - echo "

        " . _("How we protect your data") . "

        "; - echo _("In collaboration with our hosting provider we try our best to protect our - databases against access from third parties, losses, misuse or forgery. - ") . "

        "; - echo "

        " . _("Third party that receive your personal data") . "

        "; - echo "Our hosting provider can access the date we store on their server. We have a data processing agreement with them."; - echo "

        " . _("Cookies") . "

        "; - echo _("This site uses cookies – small text files that are placed on your machine to help the site provide a better user experience. - In general, cookies are used to retain user preferences, store information for things like shopping carts, - and provide anonymised tracking data to third party applications like Google Analytics. - As a rule, cookies will make your browsing experience better. However, you may prefer to disable cookies on this site and on others. - The most effective way to do this is to disable cookies in your browser. We suggest consulting the Help section of your browser - or taking a look at the About Cookies website which offers guidance for all modern browsers"); - - Template::render_footer(); diff --git a/run.sh b/run.sh new file mode 100755 index 0000000..cb40742 --- /dev/null +++ b/run.sh @@ -0,0 +1,40 @@ +#!/bin/bash + +source docker/helper.sh + + +if [ $# -eq 0 ]; then + renderHelp; + exit 0; +fi + + +case "$1" in + up) + composeUp; + ;; + + down) + composeDown; + ;; + + lint) + php ./tools/phpcs.phar --standard=./tools/ruleset.xml --extensions=php --ignore=./src/vendor,./src/config.php ./src; + ;; + + lint-sum) + php ./tools/phpcs.phar --standard=./tools/ruleset.xml --extensions=php --ignore=./src/vendor,./src/config.php --report=summary ./src; + ;; + + lint-fix) + php ./tools/phpcbf.phar --standard=./tools/ruleset.xml --extensions=php --ignore=./src/vendor,./src/config.php ./src; + ;; + + *) + echo "Bad choice, try it again.."; + exit 1; + ;; + +esac + +exit 0; diff --git a/sql/demo.sql b/sql/demo.sql new file mode 100644 index 0000000..7ffc571 --- /dev/null +++ b/sql/demo.sql @@ -0,0 +1,414 @@ +-- phpMyAdmin SQL Dump +-- version 5.1.1 +-- https://www.phpmyadmin.net/ +-- +-- Host: localhost:3306 +-- Generation Time: Oct 02, 2021 at 07:08 PM +-- Server version: 10.5.12-MariaDB-1:10.5.12+maria~focal +-- PHP Version: 7.4.24 + +SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; +START TRANSACTION; +SET time_zone = "+00:00"; + + +/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; +/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; +/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; +/*!40101 SET NAMES utf8mb4 */; + +-- +-- Database: `admin_status_beta` +-- + +-- -------------------------------------------------------- + +-- +-- Table structure for table `queue_notify` +-- + +CREATE TABLE `queue_notify` ( + `id` int(11) NOT NULL, + `task_id` int(11) NOT NULL, + `status` tinyint(1) NOT NULL, + `subscriber_id` int(11) NOT NULL, + `retries` tinyint(1) DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; + +-- -------------------------------------------------------- + +-- +-- Table structure for table `queue_task` +-- + +CREATE TABLE `queue_task` ( + `id` int(11) NOT NULL, + `type_id` int(11) NOT NULL, + `status` tinyint(1) NOT NULL, + `template_data1` text COLLATE utf8_czech_ci DEFAULT NULL, + `template_data2` text COLLATE utf8_czech_ci DEFAULT NULL, + `created_time` int(11) NOT NULL, + `completed_time` int(11) DEFAULT NULL, + `num_errors` int(11) DEFAULT NULL, + `user_id` int(11) NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; + +-- -------------------------------------------------------- + +-- +-- Table structure for table `services` +-- + +CREATE TABLE `services` ( + `id` int(11) NOT NULL, + `name` varchar(50) COLLATE utf8_czech_ci NOT NULL, + `description` varchar(200) COLLATE utf8_czech_ci NOT NULL, + `group_id` int(11) DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; + +-- +-- Dumping data for table `services` +-- + +INSERT INTO `services` (`id`, `name`, `description`, `group_id`) VALUES +(1, 'Web', 'The main web server', NULL); + +-- -------------------------------------------------------- + +-- +-- Table structure for table `services_groups` +-- + +CREATE TABLE `services_groups` ( + `id` int(11) NOT NULL, + `name` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL, + `description` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL, + `visibility` tinyint(4) NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; + +-- -------------------------------------------------------- + +-- +-- Table structure for table `services_status` +-- + +CREATE TABLE `services_status` ( + `id` int(11) NOT NULL, + `service_id` int(11) NOT NULL, + `status_id` int(11) NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; + +-- +-- Dumping data for table `services_status` +-- + +INSERT INTO `services_status` (`id`, `service_id`, `status_id`) VALUES +(1, 1, 1), +(2, 1, 2), +(3, 1, 3); + +-- -------------------------------------------------------- + +-- +-- Table structure for table `services_subscriber` +-- + +CREATE TABLE `services_subscriber` ( + `comboID` int(11) NOT NULL, + `subscriberIDFK` int(11) NOT NULL, + `serviceIDFK` int(11) NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; + +-- -------------------------------------------------------- + +-- +-- Table structure for table `settings` +-- + +CREATE TABLE `settings` ( + `setting` varchar(255) COLLATE utf8_czech_ci NOT NULL, + `value` varchar(255) COLLATE utf8_czech_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; + +-- +-- Dumping data for table `settings` +-- + +INSERT INTO `settings` (`setting`, `value`) VALUES +('cron_server_ip', ''), +('dbConfigVersion', 'Version2Beta7'), +('google_recaptcha', 'no'), +('google_recaptcha_secret', ''), +('google_recaptcha_sitekey', ''), +('mailer', 'Server Status DEV'), +('mailer_email', 'sysadmin@example.com'), +('name', 'Server Status DEV'), +('notifyUpdates', 'yes'), +('php_mailer', 'no'), +('php_mailer_host', ''), +('php_mailer_pass', ''), +('php_mailer_path', ''), +('php_mailer_port', ''), +('php_mailer_secure', 'no'), +('php_mailer_smtp', 'no'), +('php_mailer_user', ''), +('subscribe_email', 'no'), +('subscribe_telegram', 'no'), +('tg_bot_api_token', ''), +('tg_bot_username', ''), +('title', 'Server Status DEV'), +('url', 'http://server-status.localhost'); + +-- -------------------------------------------------------- + +-- +-- Table structure for table `status` +-- + +CREATE TABLE `status` ( + `id` int(11) NOT NULL, + `type` int(11) NOT NULL, + `title` varchar(50) COLLATE utf8_czech_ci NOT NULL, + `text` text COLLATE utf8_czech_ci NOT NULL, + `time` int(11) NOT NULL, + `end_time` int(11) NOT NULL, + `user_id` int(11) NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; + +-- +-- Dumping data for table `status` +-- + +INSERT INTO `status` (`id`, `type`, `title`, `text`, `time`, `end_time`, `user_id`) VALUES +(1, 0, 'Power shut down', 'We are having problems with the power grid. The issue is under investigation, should be up and running soon.', 1633114722, 0, 1), +(2, 1, 'Network problems', 'Network routers are still having a rough time after the power loss, hopefully they will be up and running soon.', 1633164722, 0, 1), +(3, 3, 'We are UP!', 'Everything is up and running again!', 1633194722, 0, 1); + +-- -------------------------------------------------------- + +-- +-- Table structure for table `subscribers` +-- + +CREATE TABLE `subscribers` ( + `subscriberID` int(11) NOT NULL, + `typeID` tinyint(1) NOT NULL, + `userID` varchar(200) COLLATE utf8mb4_unicode_ci NOT NULL, + `firstname` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL, + `lastname` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL, + `token` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL, + `expires` int(11) DEFAULT NULL, + `active` tinyint(1) DEFAULT NULL, + `create_time` int(11) DEFAULT NULL, + `update_time` int(11) DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; + +-- -------------------------------------------------------- + +-- +-- Table structure for table `tokens` +-- + +CREATE TABLE `tokens` ( + `token` varchar(64) COLLATE utf8_czech_ci NOT NULL, + `user` int(11) NOT NULL, + `expire` int(11) NOT NULL, + `data` varchar(80) COLLATE utf8_czech_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; + +-- -------------------------------------------------------- + +-- +-- Table structure for table `users` +-- + +CREATE TABLE `users` ( + `id` int(11) NOT NULL, + `email` varchar(60) COLLATE utf8_czech_ci NOT NULL, + `username` varchar(50) COLLATE utf8_czech_ci NOT NULL, + `name` varchar(50) COLLATE utf8_czech_ci NOT NULL, + `surname` varchar(50) COLLATE utf8_czech_ci NOT NULL, + `password_hash` char(64) COLLATE utf8_czech_ci NOT NULL, + `password_salt` char(64) COLLATE utf8_czech_ci NOT NULL, + `permission` int(11) NOT NULL DEFAULT 0, + `active` tinyint(1) NOT NULL DEFAULT 1 +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; + +-- +-- Dumping data for table `users` +-- + +INSERT INTO `users` (`id`, `email`, `username`, `name`, `surname`, `password_hash`, `password_salt`, `permission`, `active`) VALUES +(1, 'sysadmin@example.com', 'sysadmin', 'Sysadmin', 'DEV', '94977f202777689254e899f3846116b76e4d0652e2a03e9b2c3ef28891936e74', '1700003474615891853019f5.99130930', 0, 1); + +-- +-- Indexes for dumped tables +-- + +-- +-- Indexes for table `queue_notify` +-- +ALTER TABLE `queue_notify` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `queue_task` +-- +ALTER TABLE `queue_task` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `services` +-- +ALTER TABLE `services` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `services_groups` +-- +ALTER TABLE `services_groups` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `services_status` +-- +ALTER TABLE `services_status` + ADD PRIMARY KEY (`id`), + ADD KEY `service_id` (`service_id`), + ADD KEY `status_id` (`status_id`); + +-- +-- Indexes for table `services_subscriber` +-- +ALTER TABLE `services_subscriber` + ADD PRIMARY KEY (`comboID`), + ADD UNIQUE KEY `unique_subscription` (`subscriberIDFK`,`serviceIDFK`), + ADD KEY `serviceIDFK` (`serviceIDFK`); + +-- +-- Indexes for table `settings` +-- +ALTER TABLE `settings` + ADD UNIQUE KEY `setting` (`setting`); + +-- +-- Indexes for table `status` +-- +ALTER TABLE `status` + ADD PRIMARY KEY (`id`), + ADD KEY `user_id` (`user_id`); + +-- +-- Indexes for table `subscribers` +-- +ALTER TABLE `subscribers` + ADD PRIMARY KEY (`subscriberID`), + ADD UNIQUE KEY `userID` (`userID`); + +-- +-- Indexes for table `tokens` +-- +ALTER TABLE `tokens` + ADD PRIMARY KEY (`token`), + ADD KEY `user` (`user`); + +-- +-- Indexes for table `users` +-- +ALTER TABLE `users` + ADD PRIMARY KEY (`id`), + ADD UNIQUE KEY `email` (`email`), + ADD UNIQUE KEY `username` (`username`); + +-- +-- AUTO_INCREMENT for dumped tables +-- + +-- +-- AUTO_INCREMENT for table `queue_notify` +-- +ALTER TABLE `queue_notify` + MODIFY `id` int(11) NOT NULL AUTO_INCREMENT; + +-- +-- AUTO_INCREMENT for table `queue_task` +-- +ALTER TABLE `queue_task` + MODIFY `id` int(11) NOT NULL AUTO_INCREMENT; + +-- +-- AUTO_INCREMENT for table `services` +-- +ALTER TABLE `services` + MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; + +-- +-- AUTO_INCREMENT for table `services_groups` +-- +ALTER TABLE `services_groups` + MODIFY `id` int(11) NOT NULL AUTO_INCREMENT; + +-- +-- AUTO_INCREMENT for table `services_status` +-- +ALTER TABLE `services_status` + MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; + +-- +-- AUTO_INCREMENT for table `services_subscriber` +-- +ALTER TABLE `services_subscriber` + MODIFY `comboID` int(11) NOT NULL AUTO_INCREMENT; + +-- +-- AUTO_INCREMENT for table `status` +-- +ALTER TABLE `status` + MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; + +-- +-- AUTO_INCREMENT for table `subscribers` +-- +ALTER TABLE `subscribers` + MODIFY `subscriberID` int(11) NOT NULL AUTO_INCREMENT; + +-- +-- AUTO_INCREMENT for table `users` +-- +ALTER TABLE `users` + MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; + +-- +-- Constraints for dumped tables +-- + +-- +-- Constraints for table `services_status` +-- +ALTER TABLE `services_status` + ADD CONSTRAINT `service_id` FOREIGN KEY (`service_id`) REFERENCES `services` (`id`), + ADD CONSTRAINT `status_id` FOREIGN KEY (`status_id`) REFERENCES `status` (`id`); + +-- +-- Constraints for table `services_subscriber` +-- +ALTER TABLE `services_subscriber` + ADD CONSTRAINT `services_subscriber_ibfk_1` FOREIGN KEY (`subscriberIDFK`) REFERENCES `subscribers` (`subscriberID`) ON DELETE CASCADE ON UPDATE CASCADE, + ADD CONSTRAINT `services_subscriber_ibfk_2` FOREIGN KEY (`serviceIDFK`) REFERENCES `services` (`id`) ON DELETE CASCADE ON UPDATE CASCADE; + +-- +-- Constraints for table `status` +-- +ALTER TABLE `status` + ADD CONSTRAINT `user_id` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`); + +-- +-- Constraints for table `tokens` +-- +ALTER TABLE `tokens` + ADD CONSTRAINT `user` FOREIGN KEY (`user`) REFERENCES `users` (`id`); +COMMIT; + +/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; +/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; +/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; diff --git a/src/404.php b/src/404.php new file mode 100644 index 0000000..c6040e3 --- /dev/null +++ b/src/404.php @@ -0,0 +1,16 @@ + +
        +

        +

        +
        + Very simple server status page written in PHP that can run on **PHP 5.4+** - even on **shared webhosting** even without shell access. Because why waste your money on another server (or host on a server that you might want to do maintenance on), when you can use cheap webhosting? And as a cherry on top - it works even without javascript! ## How do I install this thing? diff --git a/SECURITY.md b/src/SECURITY.md similarity index 100% rename from SECURITY.md rename to src/SECURITY.md diff --git a/src/admin/dashboard.php b/src/admin/dashboard.php new file mode 100644 index 0000000..cbdefab --- /dev/null +++ b/src/admin/dashboard.php @@ -0,0 +1,105 @@ +render_incidents(false, $_GET['offset'], 5); + exit(); +} elseif (isset($_GET['offset'])) { + $offset = $_GET['offset']; +} + +if (isset($_GET['new']) && $_GET['new'] == "incident") { + Incident::add(); +} + +if (isset($_GET['delete'])) { + Incident::delete($_GET['delete']); +} + +if (isset($_GET['tasks'])) { + Queue::process_queue(); +} + +Template::render_header(_("Dashboard"), 'dashboard', true); +?> + +
        +

        +

        get_name();?>

        +
        + +
        + render_status(true); + ?> +
        +
        +
        +

        +
        + +

        + +
          + +
        • + get_status() != -1) { + ?>get_id(), $post_services)) ? "checked" : '';?> id="service-get_id(); ?>"> +
          get_status() != -1) { + echo $statuses[$service->get_status()]; + }?>
          +
        • + +
        +
        +
        + +
        +
        + " value="" required> "> + + +
        +
        + +
        + +
        + + +
        + render_incidents(true, $offset, 5, true); + $constellation->render_incidents(false, $offset, 5, true); + ?> +
        +
        + diff --git a/src/admin/index.php b/src/admin/index.php new file mode 100644 index 0000000..101f639 --- /dev/null +++ b/src/admin/index.php @@ -0,0 +1,122 @@ +getSetting($mysqli, 'name')); + define('TITLE', $db->getSetting($mysqli, 'title')); + define('WEB_URL', $db->getSetting($mysqli, 'url')); + define('MAILER_NAME', $db->getSetting($mysqli, 'mailer')); + define('MAILER_ADDRESS', $db->getSetting($mysqli, 'mailer_email')); + + define('GOOGLE_RECAPTCHA', $db->getBooleanSetting($mysqli, 'google_recaptcha')); + define('GOOGLE_RECAPTCHA_SECRET', $db->getSetting($mysqli, 'google_recaptcha_secret')); + define('GOOGLE_RECAPTCHA_SITEKEY', $db->getSetting($mysqli, 'google_recaptcha_sitekey')); + define('SUBSCRIBE_EMAIL', $db->getBooleanSetting($mysqli, 'subscribe_email')); + define('SUBSCRIBE_TELEGRAM', $db->getBooleanSetting($mysqli, 'subscribe_telegram')); + define('TG_BOT_USERNAME', $db->getSetting($mysqli, 'tg_bot_username')); + define('TG_BOT_API_TOKEN', $db->getSetting($mysqli, 'tg_bot_api_token')); + define('PHP_MAILER', $db->getBooleanSetting($mysqli, 'php_mailer')); + define('PHP_MAILER_SMTP', $db->getBooleanSetting($mysqli, 'php_mailer_smtp')); + define('PHP_MAILER_PATH', $db->getSetting($mysqli, 'php_mailer_path')); + define('PHP_MAILER_HOST', $db->getSetting($mysqli, 'php_mailer_host')); + define('PHP_MAILER_PORT', $db->getSetting($mysqli, 'php_mailer_port')); + define('PHP_MAILER_SECURE', $db->getBooleanSetting($mysqli, 'php_mailer_secure')); + define('PHP_MAILER_USER', $db->getSetting($mysqli, 'php_mailer_user')); + define('PHP_MAILER_PASS', $db->getSetting($mysqli, 'php_mailer_pass')); + define('CRON_SERVER_IP', $db->getSetting($mysqli, 'cron_server_ip')); + + // Process the subscriber notification queue + // If CRON_SERVER_IP is not set, call notification once incident has been saved + if (empty(CRON_SERVER_IP)) { + if (isset($_GET['sent']) && $_GET['sent'] == true) { + Queue::process_queue(); + } + } elseif (isset($_GET['task']) && $_GET['task'] == 'cron') { + // Else, base it on call to /admin?task=cron being called from IP defined by CRON_SERVER_IP + if (! empty(CRON_SERVER_IP) && $_SERVER['REMOTE_ADDR'] == CRON_SERVER_IP) { + Queue::process_queue(); + syslog(1, 'CRON server processed'); + } else { + syslog(1, 'CRON called from unauthorised server'); + } + } + + + if (isset($_COOKIE['user']) && !isset($_SESSION['user'])) { + User::restore_session(); + } + + if (!isset($_SESSION['user'])) { + if (isset($_GET['do']) && $_GET['do'] == 'lost-password') { + include_once 'lost-password.php'; + } elseif (isset($_GET['do']) && $_GET['do'] == 'change-email') { + $user_pwd = new User($_GET['id']); + $user_pwd->change_email(); + include_once 'login-form.php'; + } else { + User::login(); + include_once 'login-form.php'; + } + } else { + $user = new User($_SESSION['user']); + if (!$user->is_active()) { + User::logout(); + } + + if (!isset($_GET['do'])) { + $do = ''; + } else { + $do = $_GET['do']; + } + + switch ($do) { + case 'change-email': + $user = new User($_GET['id']); + $user->change_email(); + case 'user': + include_once 'user.php'; + break; + + case 'settings': + include_once 'settings.php'; + break; + + case 'new-user': + include_once 'new-user.php'; + break; + + case 'new-service': + case 'edit-service': + include_once 'service.php'; + break; + + case 'new-service-group': + case 'edit-service-group': + include_once 'service-group.php'; + break; + + case 'options': + include_once 'options.php'; + break; + + case 'logout': + User::logout(); + break; + + default: + include_once 'dashboard.php'; + break; + }//end switch + + Template::render_footer(true); + }//end if +}//end if diff --git a/src/admin/login-form.php b/src/admin/login-form.php new file mode 100644 index 0000000..5f204a1 --- /dev/null +++ b/src/admin/login-form.php @@ -0,0 +1,32 @@ + +
        +

        +
        +
        + +

        + +

        + +
        +
        + + +
        +
        + + +
        + + +
        +
        +
        + +
        +
        +
        +

        @@ -7,66 +7,58 @@
        change_password($_POST['token']); - if (isset($message)){?> + if (isset($message)) {?>

        - - + +

        - + if (isset($message)) {?>

        - +

        - + } else { + if (isset($message)) {?>

        - + -
        +
        " type="email" required> - +
        - -

        get_name(), $user->get_username());?>

        + +

        get_name(), $user->get_username());?>

        " type="password" class="form-control" name="password"> " type="password" class="form-control" name="password_repeat"> - - + + - +
        - +
        +

        Add new user

        +
        + +
        + +

        + +
        +
        +
        +
        +
        +
        +
        +
        +
        +
        +
        + + +
        +
        + +
        diff --git a/src/admin/options.php b/src/admin/options.php new file mode 100644 index 0000000..80dbce2 --- /dev/null +++ b/src/admin/options.php @@ -0,0 +1,194 @@ +getBooleanSetting($mysqli, 'notifyUpdates'); +$emailSubscription_status = $db->getBooleanSetting($mysqli, 'subscribe_email'); +$telegramSubscription_status = $db->getBooleanSetting($mysqli, 'subscribe_telegram'); +$tg_bot_api_token = $db->getSetting($mysqli, 'tg_bot_api_token'); +$tg_bot_username = $db->getSetting($mysqli, 'tg_bot_username'); +$php_mailer_status = $db->getBooleanSetting($mysqli, 'php_mailer'); +$php_mailer_smtp_status = $db->getBooleanSetting($mysqli, 'php_mailer_smtp'); +$php_mailer_secure_status = $db->getBooleanSetting($mysqli, 'php_mailer_secure'); +$php_mailer_path = $db->getSetting($mysqli, 'php_mailer_path'); +$php_mailer_host = $db->getSetting($mysqli, 'php_mailer_host'); +$php_mailer_port = $db->getSetting($mysqli, 'php_mailer_port'); +$php_mailer_user = $db->getSetting($mysqli, 'php_mailer_user'); +$php_mailer_pass = $db->getSetting($mysqli, 'php_mailer_pass'); +$cron_server_ip = $db->getSetting($mysqli, 'cron_server_ip'); +$google_rechaptcha_status = $db->getBooleanSetting($mysqli, 'google_recaptcha'); +$google_recaptcha_sitekey = $db->getSetting($mysqli, 'google_recaptcha_sitekey'); +$google_recaptcha_secret = $db->getSetting($mysqli, 'google_recaptcha_secret'); + +$db->getSetting($mysqli, ''); +$set_post = false; +if (!empty($_POST)) { + $db->updateSetting($mysqli, 'notifyUpdates', getToggle($_POST['nu_toggle'])); + $db->updateSetting($mysqli, 'name', htmlspecialchars($_POST['sitename'], ENT_QUOTES)); + $db->updateSetting($mysqli, 'subscribe_email', getToggle($_POST['email_subscription_toggle'])); + $db->updateSetting($mysqli, 'subscribe_telegram', getToggle($_POST['telegram_subscription_toggle'])); + $db->updateSetting($mysqli, 'tg_bot_api_token', htmlspecialchars($_POST['tg_bot_api_token'], ENT_QUOTES)); + $db->updateSetting($mysqli, 'tg_bot_username', htmlspecialchars($_POST['tg_bot_username'], ENT_QUOTES)); + $db->updateSetting($mysqli, 'php_mailer', getToggle($_POST['php_mailer_toggle'])); + $db->updateSetting($mysqli, 'php_mailer_smtp', getToggle($_POST['php_mailer_smtp_toggle'])); + $db->updateSetting($mysqli, 'php_mailer_secure', getToggle($_POST['php_mailer_secure_toggle'])); + $db->updateSetting($mysqli, 'php_mailer_path', htmlspecialchars($_POST['php_mailer_path'], ENT_QUOTES)); + $db->updateSetting($mysqli, 'php_mailer_host', htmlspecialchars($_POST['php_mailer_host'], ENT_QUOTES)); + $db->updateSetting($mysqli, 'php_mailer_port', htmlspecialchars($_POST['php_mailer_port'], ENT_QUOTES)); + $db->updateSetting($mysqli, 'php_mailer_user', htmlspecialchars($_POST['php_mailer_user'], ENT_QUOTES)); + $db->updateSetting($mysqli, 'php_mailer_pass', htmlspecialchars($_POST['php_mailer_pass'], ENT_QUOTES)); + $db->updateSetting($mysqli, 'cron_server_ip', htmlspecialchars($_POST['cron_server_ip'], ENT_QUOTES)); + $db->updateSetting($mysqli, 'google_recaptcha', getToggle($_POST['google_rechaptcha_toggle'])); + $db->updateSetting($mysqli, 'google_recaptcha_sitekey', htmlspecialchars($_POST['google_recaptcha_sitekey'], ENT_QUOTES)); + $db->updateSetting($mysqli, 'google_recaptcha_secret', htmlspecialchars($_POST['google_recaptcha_secret'], ENT_QUOTES)); + + $set_post = true; + /* + if($nu_toggle == "yes"){ + $notifyUpdates_status = true; + } else { + $notifyUpdates_status = false; + }*/ + // TODO - Reload page to prevent showing old values! or update variables being displayed + header('Location: '.$uri = $_SERVER['REQUEST_URI']); + // TODO - The code below will not happen ... + /* + define("NAME", $db->getSetting($mysqli,"name")); + define("TITLE", $db->getSetting($mysqli,"title")); + define("WEB_URL", $db->getSetting($mysqli,"url")); + define("MAILER_NAME", $db->getSetting($mysqli,"mailer")); + define("MAILER_ADDRESS", $db->getSetting($mysqli,"mailer_email")); + define("SUBSCRIBER_EMAIL", $db->getSetting($mysqli,"subscriber_email")); + define("SUBSCRIBER_TELEGRAM", $db->getSetting($mysqli,"subscriber_telegram")); + define("TG_BOT_API_TOKEN", $db->getSetting($mysqli,"tg_bot_api_token")); + define("TG_BOT_USERNAME", $db->getSetting($mysqli,"tg_bot_username")); + define("GOOGLE_RECAPTCHA", $db->getSetting($mysqli,"google_recaptcha")); + define("GOOGLE_RECAPTCHA_SITEKEY", $db->getSetting($mysqli,"google_recaptcha_sitekey")); + define("GOOGLE_RECAPTCHA_SECRET", $db->getSetting($mysqli,"google_recaptcha_secret")); + define("PHP_MAILER", $db->getSetting($mysqli,"php_mailer")); + define("PHP_MAILER_PATH", $db->getSetting($mysqli,"php_mailer_path")); + define("PHP_MAILER_SMTP", $db->getSetting($mysqli,"php_mailer_smtp")); + define("PHP_MAILER_HOST", $db->getSetting($mysqli,"php_mailer_host")); + define("PHP_MAILER_PORT", $db->getSetting($mysqli,"php_mailer_port")); + define("PHP_MAILER_SECURE", $db->getSetting($mysqli,"php_mailer_secure")); + define("PHP_MAILER_USER", $db->getSetting($mysqli,"php_mailer_user")); + define("PHP_MAILER_PASS", $db->getSetting($mysqli,"php_mailer_pass")); + define("CRON_SERVER_IP", $db->getSetting($mysqli,"cron_server_ip")); + */ +}//end if + +Template::render_header(_('Options'), 'options', true); +?> +
        +

        + +

        +
        +
        + +
        +
        + Site Name +
        + +
        + + + + +
        +
        + Telegram BOT API Token +
        + +
        +
        +
        + Telegram BOT Username +
        + +
        + + + + +
        +
        + PHPMailer Path +
        + +
        +
        +
        + PHPMailer SMTP Host +
        + +
        +
        +
        + PHPMailer SMTP Port +
        + +
        +
        +
        + PHPMailer Username +
        + +
        +
        +
        + PHPMailer Password +
        + +
        +
        +
        + Cron Server IP +
        + +
        + + +
        +
        + Google reChaptcha Sitekey +
        + +
        +
        +
        + Google reChaptcha Secret +
        + +
        + + + + +
        diff --git a/src/admin/service-group.php b/src/admin/service-group.php new file mode 100644 index 0000000..83b0f70 --- /dev/null +++ b/src/admin/service-group.php @@ -0,0 +1,90 @@ +prepare('SELECT * FROM services_groups WHERE id LIKE ?'); + $stmt->bind_param('i', $group_id); + $stmt->execute(); + $query = $stmt->get_result(); + $data = $query->fetch_assoc(); + $group_value = $data['name']; + $description_value = $data['description']; + $visibility_id_value = $data['visibility']; +} + + +if (!$boolEdit) { + Template::render_header(_('New service group'), 'service-group', true); ?> +
        +

        +
        + +
        +

        +
        + + +
        + +

        + +
        +
        +
        +
        +
        +
        + + +
        +
        + '; + } + ?> + +
        diff --git a/src/admin/service.php b/src/admin/service.php new file mode 100644 index 0000000..434883c --- /dev/null +++ b/src/admin/service.php @@ -0,0 +1,92 @@ +prepare('SELECT * FROM services WHERE id LIKE ?'); + $stmt->bind_param('i', $service_id); + $stmt->execute(); + $query = $stmt->get_result(); + $data = $query->fetch_assoc(); + // print_r($data); + $service_value = $data['name']; + $description_value = $data['description']; + $group_id_value = $data['group_id']; +} + + +if (!$boolEdit) { + Template::render_header(_('New service'), 'service', true); ?> +
        +

        +
        + +
        +

        +
        + +
        + +

        + +
        +
        +
        +
        +
        +
        + + +
        +
        + '; + } + ?> + +
        diff --git a/src/admin/settings.php b/src/admin/settings.php new file mode 100644 index 0000000..df1808b --- /dev/null +++ b/src/admin/settings.php @@ -0,0 +1,143 @@ + +
        +

        Settings

        +
        + +

        + +
        +

        + get_rank() <= 1) { ?> +
        +
        + +
        +
        + +
        + + + + + + + + get_rank() <= 1) { ?> + + + + + + query('SELECT services.*, services_groups.name AS group_name FROM `services` LEFT JOIN services_groups ON services.group_id = services_groups.id ORDER BY services.name ASC'); + while ($result = $query->fetch_assoc()) { + echo ''; + // echo ""; + echo ''; + echo ''; + + if ($user->get_rank() <= 1) { + echo ''; + } + + echo ''; + } + ?> + +
        ".$result['id']."'.$result['name'].''; + echo ''.$result['description'].''.$result['group_name'].'
        +
        +
        + +
        +

        + get_rank() <= 1) { ?> +
        +
        + +
        +
        + +
        + + + + + + + + + get_rank() <= 1) { ?> + + + + + + query('SELECT sg.* , (SELECT COUNT(*) FROM services WHERE services.group_id = sg.id) AS counter FROM services_groups AS sg ORDER BY sg.id ASC'); + while ($result = $query->fetch_assoc()) { + echo ''; + // echo ""; + echo ''; + echo ''; + + if ($user->get_rank() <= 1) { + echo ''; + } + + echo ''; + } + ?> + +
        ".$result['id']."'.$result['name'].''; + echo ' '.$result['counter'].''; + echo ''.$result['description'].''.$visibility[$result['visibility']].'
        +
        +
        + + +
        +

        + get_rank() == 0) { + ?> + + +
        + + + + + query('SELECT * FROM users'); + while ($result = $query->fetch_assoc()) { + echo ''; + echo ''; + echo "'; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + } + ?> + +
        Active
        '.$result['id'].'".$result['username'].''.$result['name'].''.$result['surname'].''.$result['email'].''.$permissions[$result['permission']].''; + echo ""; + echo '
        +
        +
        diff --git a/src/admin/user.php b/src/admin/user.php new file mode 100644 index 0000000..5cf13d3 --- /dev/null +++ b/src/admin/user.php @@ -0,0 +1,56 @@ +change_password(); +} + +if (isset($_POST['username'])) { + $displayed_user->change_username(); +} + +if (isset($_POST['name'])) { + $displayed_user->change_name(); +} + +if (isset($_POST['email'])) { + $success = $displayed_user->email_link(); +} + +if (isset($_POST['permission'])) { + $displayed_user->change_permission(); +} + + +if (isset($_GET['what']) && $_GET['what'] == 'toggle') { + $displayed_user->toggle(); +} + +Template::render_header(_("User"), 'user', true); + +?> +
        +

        +
        + +

        + +

        +render_user_settings(); \ No newline at end of file diff --git a/src/api/incidents.php b/src/api/incidents.php new file mode 100644 index 0000000..2430ef0 --- /dev/null +++ b/src/api/incidents.php @@ -0,0 +1,17 @@ +get_incidents((isset($_GET['future']) ? $_GET['future'] : false), $offset, $limit, $timestamp); + header('Cache-Control: no-cache'); + header('Content-type: application/json'); + echo json_encode($result); +} diff --git a/src/api/status.php b/src/api/status.php new file mode 100644 index 0000000..fe940c5 --- /dev/null +++ b/src/api/status.php @@ -0,0 +1,36 @@ +render_status(true, false); + echo json_encode($array); + } else { + $query = $mysqli->prepare('SELECT name FROM services WHERE id=?'); + $query->bind_param('i', $_GET['id']); + $query->execute(); + $result = $query->get_result()->fetch_assoc(); + if (!count($result)) { + die(json_encode(['error' => _('Service does not exist!')])); + } + + $sql = $mysqli->prepare('SELECT type FROM services_status INNER JOIN status ON services_status.status_id = status.id WHERE service_id = ? AND `time` <= ? AND (`end_time` >= ? OR `end_time`=0) ORDER BY `time` DESC LIMIT 1'); + + $sql->bind_param('iii', $id, $timestamp, $timestamp); + $sql->execute(); + $tmp = $sql->get_result(); + if ($tmp->num_rows) { + $service = new Service($_GET['id'], $result['name'], $tmp->fetch_assoc()['type']); + } else { + $service = new Service($_GET['id'], $result['name']); + } + + echo json_encode($service); + }//end if +}//end if diff --git a/src/classes/constellation.php b/src/classes/constellation.php new file mode 100644 index 0000000..474479b --- /dev/null +++ b/src/classes/constellation.php @@ -0,0 +1,234 @@ +get_incidents($future, $offset, $limit, $timestamp); + + $ajax = isset($_GET['ajax']); + + if ($future && count($incidents["incidents"]) && !$ajax) { + echo "

        " . _("Planned maintenance") . "

        "; + } elseif (count($incidents["incidents"]) && !$ajax) { + if ($offset) { + echo ''; + } + echo "

        " . _("Past incidents") . "

        "; + } elseif (!$future && !$ajax) { + echo "

        " . _("No incidents") . "

        "; + } + $show = !$future && $incidents["more"]; + + $offset += $limit; + + if (count($incidents["incidents"])) { + foreach ($incidents['incidents'] as $incident) { + $incident->render($admin); + } + + if ($show) { + echo ''; + } + } + } + + /** + * Renders service status - in admin page it returns array so it can be processed further. + * + * @param boolean $admin + * @return array of services + */ + public function render_status($admin = false, $heading = true) + { + global $mysqli; + + //$query = $mysqli->query("SELECT id, name, description FROM services"); + $query = $mysqli->query("SELECT services.id, services.name, services.description, services_groups.name as group_name FROM services LEFT JOIN services_groups ON services.group_id=services_groups.id ORDER BY services_groups.name ASC, services.id ASC "); + $array = array(); + $groups = array(); + if ($query->num_rows) { + $timestamp = time(); + + while ($result = $query->fetch_assoc()) { + $id = $result['id']; + $sql = $mysqli->prepare("SELECT type FROM services_status INNER JOIN status ON services_status.status_id = status.id WHERE service_id = ? AND `time` <= ? AND (`end_time` >= ? OR `end_time`=0) ORDER BY `time` DESC LIMIT 1"); + + $sql->bind_param("iii", $id, $timestamp, $timestamp); + $sql->execute(); + $tmp = $sql->get_result(); + + if (!isset($groups[$result['group_name']])) { + $groups[$result['group_name']] = array(); + } + + if ($tmp->num_rows) { + $service = new Service($result['id'], $result['name'], $result['description'], $result['group_name'], $tmp->fetch_assoc()['type']); + ; + $array[] = $service; + $groups[$result['group_name']][] = $service; + } else { + $service = new Service($result['id'], $result['name'], $result['description'], $result['group_name']); + ; + $array[] = $service; + $groups[$result['group_name']][] = $service; + } + } + if ($heading) { + echo Service::current_status($array); + } + } else { + $array[] = new Service(0, _("No services"), -1); + } + if (!$admin) { + ?> + query("SELECT name, visibility FROM services_groups"); + + $visibility = array(); + while ($result = $query->fetch_assoc()) { + $visibility[$result['name']] = $result['visibility']; + } + + + foreach ($groups as $key => $group) { + if (!empty($key)) { + $visibility_class = 'collapsed'; + + $status = Service::group_status($group); + + if ($visibility[$key] == 1 || ($visibility[$key] == 2 && $status != 5)) { + $visibility_class = ''; + } + + echo '
          '; + // echo '
            '; + // Render the group status if it exists + echo '
          • + '.$key.' +
            '._($statuses[$status]).'
            +
          • '; + } else { + echo '
              '; + } + + foreach ($group as $service) { + $service->render(); + } + echo '
            '; + } + } else { + return $array; + } + } + + + function get_incidents($future = false, $offset = 0, $limit = 5, $timestamp = 0) + { + global $mysqli; + if ($timestamp == 0) { + $timestamp = time(); + } + + $operator = ($future) ? ">=" : "<="; + $limit++; + $sql = $mysqli->prepare("SELECT users.id, status.type, status.title, status.text, status.time, status.end_time, users.username, status.id as status_id FROM status INNER JOIN users ON user_id=users.id WHERE `time` $operator ? AND `end_time` $operator ? OR (`time`<=? AND `end_time` $operator ? ) ORDER BY `time` DESC LIMIT ? OFFSET ?"); + $sql->bind_param("iiiiii", $timestamp, $timestamp, $timestamp, $timestamp, $limit, $offset); + $sql->execute(); + $query = $sql->get_result(); + $array = []; + $limit--; + $more = false; + if ($query->num_rows > $limit) { + $more = true; + } + if ($query->num_rows) { + while (($result = $query->fetch_assoc()) && $limit-- > 0) { + // Add service id and service names to an array in the Incident class + $stmt_service = $mysqli->prepare( + "SELECT services.id,services.name FROM services + INNER JOIN services_status ON services.id = services_status.service_id + WHERE services_status.status_id = ?" + ); + $stmt_service->bind_param("i", $result['status_id']); + $stmt_service->execute(); + $query_service = $stmt_service->get_result(); + while ($result_service = $query_service->fetch_assoc()) { + $result['service_id'][] = $result_service['id']; + $result['service_name'][] = $result_service['name']; + } + + $array[] = new Incident($result); + } + } + return [ + "more" => $more, + "incidents" => $array + ]; + } + + + function render_warning($header, $message, $show_link = false, $url = null, $link_text = null) + { + $this->render_alert('alert-warning', $header, $message, $show_link, $url, $link_text); + } + function render_success($header, $message, $show_link = false, $url = null, $link_text = null) + { + $this->render_alert('alert-success', $header, $message, $show_link, $url, $link_text); + } + + /** + * Renders an alert on screen with an optional button to return to a given URL + * + * @param string alert_type - Type of warning to render alert-danger, alert-warning, alert-success etc + * @param string header - Title of warning + * @param string message - Message to display + * @param boolean show_link - True if button is to be displayed + * @param string url - URL for button + * @param string link_txt - Text for button + * @return void + */ + function render_alert($alert_type, $header, $message, $show_link = false, $url = null, $link_text = null) + { + echo '

            +
            '; + if ($show_link) { + echo ''; + } + } +} + +$constellation = new Constellation(); diff --git a/src/classes/db-class.php b/src/classes/db-class.php new file mode 100644 index 0000000..289d277 --- /dev/null +++ b/src/classes/db-class.php @@ -0,0 +1,70 @@ +query($sql) === true) { + return true; + } else { + return $conn->error; + } + }//end execute() + + + function getSetting($conn, $setting) + { + $sql = "SELECT value FROM settings WHERE setting='".$setting."'"; + $result = $conn->query($sql); + + if ($result->num_rows == 1) { + while ($row = $result->fetch_assoc()) { + return $row['value']; + } + } else { + return 'null'; + } + }//end getSetting() + + + function setSetting($conn, $settingname, $settingvalue) + { + $sql = "INSERT INTO settings (setting,value) VALUES ('".$settingname."','".$settingvalue."');"; + if ($conn->query($sql) === true) { + return true; + } else { + return $conn->error; + } + }//end setSetting() + + + function deleteSetting($conn, $settingname) + { + $sql = 'DELETE FROM settings WHERE setting="'.$settingname.'";'; + if ($conn->query($sql) === true) { + return true; + } else { + return $conn->error; + } + }//end deleteSetting() + + + function updateSetting($conn, $settingname, $settingvalue) + { + $this->deleteSetting($conn, $settingname); + $this->setSetting($conn, $settingname, $settingvalue); + return true; + }//end updateSetting() + + + function getBooleanSetting($conn, $setting) + { + if (trim($this->getSetting($conn, $setting)) == 'yes') { + return true; + } + + return false; + }//end getBooleanSetting() +}//end class diff --git a/classes/incident.php b/src/classes/incident.php similarity index 56% rename from classes/incident.php rename to src/classes/incident.php index 3a3cd0a..c5d63ee 100644 --- a/classes/incident.php +++ b/src/classes/incident.php @@ -1,9 +1,10 @@ id = $data['status_id']; $this->timestamp = $data['time']; $this->end_timestamp = $data['end_time']; - $this->date = new DateTime("@".$data['time']); + $this->date = new DateTime("@" . $data['time']); $this->date = $this->date->format('Y-m-d H:i:sP'); - if ($data['end_time']>0){ - $this->end_date = new DateTime("@".$data['end_time']); + if ($data['end_time'] > 0) { + $this->end_date = new DateTime("@" . $data['end_time']); $this->end_date = $this->end_date->format('Y-m-d H:i:sP'); } $this->type = $data['type']; @@ -42,21 +44,21 @@ function __construct($data) $this->service_name = $data['service_name']; } - /** - * Deletes incident by ID. - * @param int ID - */ - public static function delete($id){ + /** + * Deletes incident by ID. + * + * @param int ID + */ + public static function delete($id) + { global $mysqli, $message, $user; - if ($user->get_rank() > 1) - { + if ($user->get_rank() > 1) { $stmt = $mysqli->prepare("SELECT count(*) as count FROM status WHERE id= ? AND user_id = ?"); $stmt->bind_param("ii", $id, $_SESSION['user']); $stmt->execute(); $query = $stmt->get_result(); - if (!$query->fetch_assoc()['count']) - { + if (!$query->fetch_assoc()['count']) { $message = _("You don't have permission to do that!"); return; } @@ -71,19 +73,20 @@ public static function delete($id){ $stmt->bind_param("i", $id); $stmt->execute(); $query = $stmt->get_result(); - header("Location: ".WEB_URL."/admin"); + header("Location: " . WEB_URL . "/admin"); } - /** - * Processes submitted form and adds incident unless problem is encountered, - * calling this is possible only for admin or higher rank. Also checks requirements - * for char limits. - * @return void - */ + /** + * Processes submitted form and adds incident unless problem is encountered, + * calling this is possible only for admin or higher rank. Also checks requirements + * for char limits. + * + * @return void + */ public static function add() { global $mysqli, $message; - //Sould be a better way to get this array... + //Sould be a better way to get this array... $statuses = array(_("Major outage"), _("Minor outage"), _("Planned maintenance"), _("Operational") ); $user_id = $_SESSION['user']; @@ -91,70 +94,59 @@ public static function add() $title = strip_tags($_POST['title']); $text = strip_tags($_POST['text'], '
            '); - if (strlen($title)==0) - { + if (strlen($title) == 0) { $message = _("Please enter title"); return; - }else if(strlen($title)>50){ + } elseif (strlen($title) > 50) { $message = _("Title too long! Character limit is 50"); return; } - if (strlen($title)==0) - { + if (strlen($title) == 0) { $message = _("Please enter text"); return; } - if ($type == 2 && (!strlen(trim($_POST['time'])) || !strlen(trim($_POST['end_time'])))) - { + if ($type == 2 && (!strlen(trim($_POST['time'])) || !strlen(trim($_POST['end_time'])))) { $message = _("Please set start and end time! Use ISO 8601 format."); return; } - if (empty($_POST['services'])){ + if (empty($_POST['services'])) { $message = _("Please select at least one service"); - } - else - { - if (!is_array($_POST['services'])) - { + } else { + if (!is_array($_POST['services'])) { $services = array($_POST['services']); - } - else - { + } else { $services = $_POST['services']; } - if (!empty($_POST['time']) && $type == 2){ - $input_time = (!empty($_POST['time_js'])?$_POST['time_js']: $_POST['time']); - $input_end_time = (!empty($_POST['end_time_js'])?$_POST['end_time_js']: $_POST['end_time']); + if (!empty($_POST['time']) && $type == 2) { + $input_time = (!empty($_POST['time_js']) ? $_POST['time_js'] : $_POST['time']); + $input_end_time = (!empty($_POST['end_time_js']) ? $_POST['end_time_js'] : $_POST['end_time']); $time = strtotime($input_time); $end_time = strtotime($input_end_time); - if (!$time) - { + if (!$time) { $message = _("Start date format is not recognized. Please use ISO 8601 format."); return; } - if (!$end_time) - { + if (!$end_time) { $message = _("End date format is not recognized. Please use ISO 8601 format."); return; } - if ($time >= $end_time) - { + if ($time >= $end_time) { $message = _("End time is either the same or earlier than start time!"); return; } - }else{ + } else { $time = time(); $end_time = ''; } $stmt = $mysqli->prepare("INSERT INTO status VALUES (NULL,?, ?, ?, ?, ?, ?)"); - $stmt->bind_param("issiii", $type, $title, $text, $time ,$end_time ,$user_id); + $stmt->bind_param("issiii", $type, $title, $text, $time, $end_time, $user_id); $stmt->execute(); $query = $stmt->get_result(); $status_id = $mysqli->insert_id; @@ -166,7 +158,7 @@ public static function add() $query = $stmt->get_result(); } - // Perform notification to subscribers + // Perform notification to subscribers $notify = new Notification(); $notify->populate_impacted_services($status_id); @@ -178,52 +170,55 @@ public static function add() $notify->notify_subscribers(); - header("Location: ".WEB_URL."/admin?sent=true"); + header("Location: " . WEB_URL . "/admin?sent=true"); } } - /** - * Renders incident - * @param Boolean $admin - decides whether admin controls should be rendered - * @return void - */ - public function render($admin=0){ + /** + * Renders incident + * + * @param Boolean $admin - decides whether admin controls should be rendered + * @return void + */ + public function render($admin = 0) + { global $icons; global $classes, $user; - $admin = $admin && (($user->get_rank()<=1) || ($user->get_username() == $this->username)); + $admin = $admin && (($user->get_rank() <= 1) || ($user->get_username() == $this->username)); $Parsedown = new Parsedown(); ?> -
            -
            +
            +
            -
            -

            title; ?>

            - id.'" class="pull-right delete">'; - }?> - +
            + title; ?> + id . '" class="float-end delete">'; + }?> +
            -
            - setBreaksEnabled(true)->text($this->text); ?> +
            + setBreaksEnabled(true)->text($this->text); ?>
            -
            - $this->id, "date" => $this->timestamp, @@ -232,6 +227,6 @@ public function jsonSerialize() { "type" => $this->type, "title" => $this->title, "username" => $this->username - ]; + ]; } } diff --git a/src/classes/locale-negotiator.php b/src/classes/locale-negotiator.php new file mode 100644 index 0000000..42dc317 --- /dev/null +++ b/src/classes/locale-negotiator.php @@ -0,0 +1,330 @@ + 'Afrikaans', + 'am_ET' => 'አማርኛ', + 'ar_AE' => 'العربية', + 'ar_BH' => 'العربية', + 'ar_DZ' => 'العربية', + 'ar_EG' => 'العربية', + 'ar_IQ' => 'العربية', + 'ar_JO' => 'العربية', + 'ar_KW' => 'العربية', + 'ar_LB' => 'العربية', + 'ar_LY' => 'العربية', + 'ar_MA' => 'العربية', + 'arn_CL' => 'Mapuche', + 'ar_OM' => 'العربية', + 'ar_QA' => 'العربية', + 'ar_SA' => 'العربية', + 'ar_SY' => 'العربية', + 'ar_TN' => 'العربية', + 'ar_YE' => 'العربية', + 'as_IN' => 'অসমীয়া', + 'az_Cyrl_AZ' => 'Азәрбајҹан', + 'az_Latn_AZ' => 'Azərbaycan', + 'ba_RU' => 'Bashkir', + 'be_BY' => 'Беларуская', + 'bg_BG' => 'Български', + 'bn_BD' => 'বাংলা', + 'bn_IN' => 'বাংলা', + 'bo_CN' => 'བོད་སྐད་', + 'br_FR' => 'Brezhoneg', + 'bs_Cyrl_BA' => 'Босански', + 'bs_Latn_BA' => 'Bosanski', + 'ca_ES' => 'Català', + 'co_FR' => 'Corsican', + 'cs_CZ' => 'Čeština', + 'cy_GB' => 'Cymraeg', + 'da_DK' => 'Dansk', + 'de_AT' => 'Deutsch', + 'de_CH' => 'Deutsch', + 'de_DE' => 'Deutsch', + 'de_LI' => 'Deutsch', + 'de_LU' => 'Deutsch', + 'dsb_DE' => 'Dolnoserbšćina', + 'dv_MV' => 'Divehi', + 'el_GR' => 'Ελληνικά', + 'en_029' => 'English', + 'en_AU' => 'English', + 'en_BZ' => 'English', + 'en_CA' => 'English', + 'en_GB' => 'English', + 'en_IE' => 'English', + 'en_IN' => 'English', + 'en_JM' => 'English', + 'en_MY' => 'English', + 'en_NZ' => 'English', + 'en_PH' => 'English', + 'en_SG' => 'English', + 'en_TT' => 'English', + 'en_US' => 'English', + 'en_ZA' => 'English', + 'en_ZW' => 'English', + 'es_AR' => 'Español', + 'es_BO' => 'Español', + 'es_CL' => 'Español', + 'es_CO' => 'Español', + 'es_CR' => 'Español', + 'es_DO' => 'Español', + 'es_EC' => 'Español', + 'es_ES' => 'Español', + 'es_GT' => 'Español', + 'es_HN' => 'Español', + 'es_MX' => 'Español', + 'es_NI' => 'Español', + 'es_PA' => 'Español', + 'es_PE' => 'Español', + 'es_PR' => 'Español', + 'es_PY' => 'Español', + 'es_SV' => 'Español', + 'es_US' => 'Español', + 'es_UY' => 'Español', + 'es_VE' => 'Español', + 'et_EE' => 'Eesti', + 'eu_ES' => 'Euskara', + 'fa_IR' => 'فارسی', + 'fi_FI' => 'Suomi', + 'fil_PH' => 'Filipino', + 'fo_FO' => 'Føroyskt', + 'fr_BE' => 'Français', + 'fr_CA' => 'Français', + 'fr_CH' => 'Français', + 'fr_FR' => 'Français', + 'fr_LU' => 'Français', + 'fr_MC' => 'Français', + 'fy_NL' => 'West_frysk', + 'ga_IE' => 'Gaeilge', + 'gd_GB' => 'Gàidhlig', + 'gl_ES' => 'Galego', + 'gsw_FR' => 'Schwiizertüütsch', + 'gu_IN' => 'ગુજરાતી', + 'ha_Latn_NG' => 'Hausa', + 'he_IL' => 'עברית', + 'hi_IN' => 'हिन्दी', + 'hr_BA' => 'Hrvatski', + 'hr_HR' => 'Hrvatski', + 'hsb_DE' => 'Hornjoserbšćina', + 'hu_HU' => 'Magyar', + 'hy_AM' => 'Հայերեն', + 'id_ID' => 'Bahasa indonesia', + 'ig_NG' => 'Igbo', + 'ii_CN' => 'ꆈꌠꉙ', + 'is_IS' => 'Íslenska', + 'it_CH' => 'Italiano', + 'it_IT' => 'Italiano', + 'iu_Cans_CA' => 'Inuktitut', + 'iu_Latn_CA' => 'Inuktitut', + 'ja_JP' => '日本語', + 'ka_GE' => 'ქართული', + 'kk_KZ' => 'Қазақ тілі', + 'kl_GL' => 'Kalaallisut', + 'km_KH' => 'ខ្មែរ', + 'kn_IN' => 'ಕನ್ನಡ', + 'kok_IN' => 'कोंकणी', + 'ko_KR' => '한국어', + 'ky_KG' => 'Кыргызча', + 'lb_LU' => 'Lëtzebuergesch', + 'lo_LA' => 'ລາວ', + 'lt_LT' => 'Lietuvių', + 'lv_LV' => 'Latviešu', + 'mi_NZ' => 'Maori', + 'mk_MK' => 'Македонски', + 'ml_IN' => 'മലയാളം', + 'mn_MN' => 'Монгол', + 'mn_Mong_CN' => 'Монгол', + 'moh_CA' => 'Mohawk', + 'mr_IN' => 'मराठी', + 'ms_BN' => 'Bahasa melayu', + 'ms_MY' => 'Bahasa melayu', + 'mt_MT' => 'Malti', + 'nb_NO' => 'Norsk bokmål', + 'ne_NP' => 'नेपाली', + 'nl_BE' => 'Nederlands', + 'nl_NL' => 'Nederlands', + 'nn_NO' => 'Nynorsk', + 'nb_NO' => 'Norsk Bokmål', + 'nso_ZA' => 'Northern sotho', + 'oc_FR' => 'Occitan', + 'or_IN' => 'ଓଡ଼ିଆ', + 'pa_IN' => 'ਪੰਜਾਬੀ', + 'pl_PL' => 'Polski', + 'prs_AF' => 'Prs', + 'ps_AF' => 'پښتو', + 'pt_BR' => 'Português', + 'pt_PT' => 'Português', + 'qut_GT' => 'Qut', + 'quz_BO' => 'Quz', + 'quz_EC' => 'Quz', + 'quz_PE' => 'Quz', + 'rm_CH' => 'Rumantsch', + 'ro_RO' => 'Română', + 'ru_RU' => 'Русский', + 'rw_RW' => 'Kinyarwanda', + 'sah_RU' => 'Саха тыла', + 'sa_IN' => 'Sanskrit', + 'se_FI' => 'Davvisámegiella', + 'se_NO' => 'Davvisámegiella', + 'se_SE' => 'Davvisámegiella', + 'si_LK' => 'සිංහල', + 'sk_SK' => 'Slovenčina', + 'sl_SI' => 'Slovenščina', + 'sma_NO' => 'Southern sami', + 'sma_SE' => 'Southern sami', + 'smj_NO' => 'Lule sami', + 'smj_SE' => 'Lule sami', + 'smn_FI' => 'Anarâškielâ', + 'sms_FI' => 'Skolt sami', + 'sq_AL' => 'Shqip', + 'sr_Cyrl_BA' => 'Српски', + 'sr_Cyrl_CS' => 'Српски', + 'sr_Cyrl_ME' => 'Српски', + 'sr_Cyrl_RS' => 'Српски', + 'sr_Latn_BA' => 'Srpski', + 'sr_Latn_CS' => 'Srpski', + 'sr_Latn_ME' => 'Srpski', + 'sr_Latn_RS' => 'Srpski', + 'sr_RS' => 'Srpski', + 'sv_FI' => 'Svenska', + 'sv_SE' => 'Svenska', + 'sw_KE' => 'Kiswahili', + 'syr_SY' => 'Syriac', + 'ta_IN' => 'தமிழ்', + 'te_IN' => 'తెలుగు', + 'tg_Cyrl_TJ' => 'Tajik', + 'th_TH' => 'ไทย', + 'tk_TM' => 'Turkmen', + 'tn_ZA' => 'Tswana', + 'tr_TR' => 'Türkçe', + 'tt_RU' => 'Tatar', + 'tzm_Latn_DZ' => 'Tamaziɣt', + 'ug_CN' => 'ئۇيغۇرچە', + 'uk_UA' => 'Українська', + 'ur_PK' => 'اردو', + 'uz_Cyrl_UZ' => 'Ўзбек', + 'uz_Latn_UZ' => 'Oʻzbekcha', + 'vi_VN' => 'Tiếng việt', + 'wo_SN' => 'Wolof', + 'xh_ZA' => 'Xhosa', + 'yo_NG' => 'Èdè yorùbá', + 'zh_CN' => '中文', + 'zh_HK' => '中文', + 'zh_MO' => '中文', + 'zh_SG' => '中文', + 'zh_TW' => '中文', + 'zu_ZA' => 'Isizulu', + ]; + + + /** + * This method scans for languages and creates a list of language and its name (localized ofc.) + * + * @param string $default_language language displayed to user in case no suitable lang is found + */ + function __construct($default_language) + { + $tmp = glob(__DIR__.'/../locale/*', GLOB_ONLYDIR); + $this->default_language = $default_language; + // Works only if the server supports the locale + // This basically means $accepted_langs[] = ""; + foreach ($tmp as $value) { + $lang = basename($value); + $this->accepted_langs[$lang] = $this->all_locales[$lang]; + } + }//end __construct() + + + /** + * Returns list of accepted langs so it can be reused for rendering language list for switching... + */ + public function get_accepted_langs() + { + return $this->accepted_langs; + }//end get_accepted_langs() + + + /** + * This method does the actual negotiation. It has override parameter in case user wants to switch + * languages. + * + * @param string $override adds language to list of preffered languages with highest priority + * @return string language code that matched best with browser preferences + */ + public function negotiate($override = null) + { + $langs = []; + + if (isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) { + $http_accept_language = str_replace('-', '_', $_SERVER['HTTP_ACCEPT_LANGUAGE']); + preg_match_all('/([a-z]{1,8}(-[a-z]{1,8})?)\s*(;\s*q\s*=\s*(1|0\.[0-9]+))?/i', $http_accept_language, $lang_parse); + + if (count($lang_parse[1])) { + $langs = array_combine($lang_parse[1], $lang_parse[4]); + + foreach ($langs as $lang => $val) { + // If browser didn't send quality of language, it is 1 by default + if ($val === '') { + $langs[$lang] = 1; + } + } + + if (isset($override)) { + // More important than the best lang of browser + $langs[$override] = 2; + } + + arsort($langs, SORT_NUMERIC); + } + }//end if + + // So we have lang code as value + $langs = array_flip($langs); + // False unless we set it, so we know to set default locale + $best_match = false; + // So we have also lang code as value + $accepted_langs = array_flip($this->accepted_langs); + + global $lang; + foreach ($langs as $lang) { + if (strlen($lang) > 2) { + if (in_array($lang, $accepted_langs)) { + $best_match = $lang; + break; + } + } else { + $possible = array_filter( + $accepted_langs, + function ($key) { + global $lang; + return strpos($key, $lang) === 0; + } + ); + + if (count($possible)) { + foreach ($possible as $value) { + $best_match = $value; + } + + break; + } + }//end if + }//end foreach + + if ($best_match === false) { + $best_match = $this->default_language; + } + + return $best_match; + }//end negotiate() +}//end class diff --git a/src/classes/mailer.php b/src/classes/mailer.php new file mode 100644 index 0000000..18508e1 --- /dev/null +++ b/src/classes/mailer.php @@ -0,0 +1,190 @@ +is_utf8($to)) { + $elements = explode('@', $to); + $punycode = new Punycode(); + $domainpart = $punycode->encode(array_pop($elements)); + // Convert domain part to ascii + $to = $elements[0].'@'.$domainpart; + // Reassemble tge full email address + } + + // Send using PHP mailer if it is enabled + if (PHP_MAILER) { + include_once PHP_MAILER_PATH.'/Exception.php'; + // Exception class. + include_once PHP_MAILER_PATH.'/PHPMailer.php'; + // The main PHPMailer class. + if (PHP_MAILER_SMTP) { + include_once PHP_MAILER_PATH.'/SMTP.php'; + // SMTP class, needed if you want to use SMTP. + } + + $phpmail = new PHPMailer(false); + + $phpmail->setFrom(MAILER_ADDRESS, MAILER_NAME); + $phpmail->addReplyTo(MAILER_ADDRESS, MAILER_NAME); + // $phpmail->Debugoutput = error_log; + // Define SMTP parameters if enabled + if (PHP_MAILER_SMTP) { + $phpmail->isSMTP(); + $phpmail->Host = PHP_MAILER_HOST; + $phpmail->Port = PHP_MAILER_PORT; + $phpmail->SMTPSecure = PHP_MAILER_SECURE; + // $phpmail->SMTPDebug = 2; // Enable for debugging + // Handle authentication for SMTP if enabled + if (!empty(PHP_MAILER_USER)) { + $phpmail->SMTPAuth = true; + $phpmail->Username = PHP_MAILER_USER; + $phpmail->Password = PHP_MAILER_PASS; + } + } + + $phpmail->addAddress($to); + $phpmail->Subject = $subject; + // Send HMTL mail + if ($html) { + $phpmail->msgHtml($message); + $phpmail->AltBody = $this->convert_html_to_plain_txt($message, false); + } else { + $phpmail->Body = $message; + // Send plain text + } + + $phpmail->isHtml($html); + // use htmlmail if enabled + if (! $phpmail->send()) { + // TODO Log error message $phpmail->ErrorInfo; + return false; + } + + return true; + } else { + // Use standard PHP mail() function + $headers = "Content-Type: $content_type; \"charset=utf-8\" ".PHP_EOL; + $headers .= 'MIME-Version: 1.0 '.PHP_EOL; + $headers .= 'From: '.MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; + $headers .= 'Reply-To: '.MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; + + mail($to, $subject, $message, $headers); + // TODO log error message if mail fails + return true; + }//end if + }//end send_mail() + + + /** + * Tries to verify the domain using dns request against an MX record of the domain part + * of the passed email address. The code also handles IDN/Punycode formatted addresses which + * contains utf8 characters. + * Original code from https://stackoverflow.com/questions/19261987/how-to-check-if-an-email-address-is-real-or-valid-using-php/19262381 + * + * @param string $email Email address to check + * @return boolean True if MX record exits, false if otherwise + */ + public function verify_domain($email) + { + // TODO - Handle idn/punycode domain names without being dependent on PHP native libs. + $domain = explode('@', $email); + $punycode = new Punycode(); + $domain = $punycode->encode(array_pop($domain).'.'); + // Add dot at end of domain to avoid local domain lookups + syslog(1, $domain); + return checkdnsrr($domain, 'MX'); + }//end verify_domain() + + + /** + * Check if string contains non-english characters (detect IDN/Punycode enabled domains) + * Original code from: https://stackoverflow.com/questions/13120475/detect-non-english-chars-in-a-string + * + * @param string $str String to check for extended characters + * @return boolean True if extended characters, false otherwise + */ + public function is_utf8($str) + { + if (strlen($str) == strlen(utf8_decode($str))) { + return false; + } else { + return true; + } + }//end is_utf8() + + + /** + * Takes the input from an HTML email and convert it to plain text + * This is commonly used when sending HTML emails as a backup for email clients who can only view, or who choose to only view, + * Original code from https://github.com/DukeOfMarshall/PHP---JSON-Email-Verification/blob/master/EmailVerify.class.php + * plain text emails + * + * @param string $content The body part of the email to convert to plain text. + * @param boolean $remove_links Set to true if links should be removed from email + * @return string pain text version + */ + public function convert_html_to_plain_txt($content, $remove_links = false) + { + // TODO does not handle unsubscribe/manage subscription text very well. + // Replace HTML line breaks with text line breaks + $plain_text = str_ireplace(['
            ', '
            '], "\n\r", $content); + + // Remove the content between the tags that wouldn't normally get removed with the strip_tags function + $plain_text = preg_replace( + [ + '@]*?>.*?@siu', + '@]*?>.*?@siu', + '@]*?.*?@siu', + '@]*?.*?@siu', + ], + '', + $plain_text + ); + // Remove everything from between the tags that doesn't get removed with strip_tags function + // If the user has chosen to preserve the addresses from links + if (!$remove_links) { + $plain_text = strip_tags(preg_replace('//', ' $1 ', $plain_text)); + } + + // Remove HTML spaces + $plain_text = str_replace(' ', '', $plain_text); + + // Replace multiple line breaks with a single line break + $plain_text = preg_replace('/(\s){3,}/', "\r\n\r\n", trim($plain_text)); + + return $plain_text; + }//end convert_html_to_plain_txt() +}//end class diff --git a/src/classes/notification.php b/src/classes/notification.php new file mode 100644 index 0000000..4f6609a --- /dev/null +++ b/src/classes/notification.php @@ -0,0 +1,224 @@ +prepare('SELECT services.id, services.name FROM services INNER JOIN services_status on services.id = services_status.service_id WHERE services_status.status_id = ?'); + $stmt->bind_param('i', $status_id); + $stmt->execute(); + $query = $stmt->get_result(); + $arrServicesNames = []; + $arrServicesId = []; + while ($result = $query->fetch_assoc()) { + $arrServicesNames[] = $result['name']; + $arrServicesId[] = (int) $result['id']; + } + + $this->status_id = $status_id; + $this->servicenames = implode(',', $arrServicesNames); + $this->serviceids = implode(',', $arrServicesId); + return true; + } else { + return false; + } + }//end populate_impacted_services() + + + /** + * Loop over the list of subscribers to notify depending on impacted service(s) and + * call the differnet notification handles. + * + * @return void + */ + public function notify_subscribers() + { + global $mysqli; + // Fetch list of unique subscribers for given service + // Direct inclusion of variable without using prepare justified by the fact that + // this->serviceids are not user submitted + $sql = 'SELECT DISTINCT subscriberIDFK FROM services_subscriber WHERE serviceIDFK IN ('.$this->serviceids.')'; + $query = $mysqli->query($sql); + + // Create the queue tasks for email/telegram notifications + $queue = new Queue(); + $queue->status = $queue->all_status['populating']; + $queue->user_id = $_SESSION['user']; + + $arr_data = []; + if (SUBSCRIBE_EMAIL) { + $arr_data = $this->prepare_email(); + // Make up the base message and subject for email + $queue->type_id = $queue->all_type_id['notify_email']; + $queue->template_data1 = $arr_data['subject']; + $queue->template_data2 = $arr_data['body']; + $task_id_email = $queue->add_task(); + // syslog(1, "queue email: ". $task_id_email); + $arr_email = []; + } + + if (SUBSCRIBE_TELEGRAM) { + $arr_data = $this->prepare_telegram(); + $queue->type_id = $queue->all_type_id['notify_telegram']; + $queue->template_data1 = null; + $queue->template_data2 = $arr_data['body']; + $task_id_telegram = $queue->add_task(); + // syslog(1, "queue telegram: ". $task_id_telegram); + $arr_telegram = []; + } + + while ($subscriber = $query->fetch_assoc()) { + // Fetch list of subscriber details for already found subscriber IDs + $stmt = $mysqli->prepare('SELECT typeID FROM subscribers WHERE subscriberID = ? AND active=1'); + $stmt->bind_param('i', $subscriber['subscriberIDFK']); + $stmt->execute(); + $subscriberQuery = $stmt->get_result(); + + while ($subscriberData = $subscriberQuery->fetch_assoc()) { + $typeID = $subscriberData['typeID']; + // Telegram = 1, email = 2 + // Handle telegram + if ($typeID == 1 && SUBSCRIBE_TELEGRAM) { + $arr_telegram[] = $subscriber['subscriberIDFK']; + } + + // Handle email + if ($typeID == 2 && SUBSCRIBE_EMAIL) { + $arr_email[] = $subscriber['subscriberIDFK']; + } + } + }//end while + + if (SUBSCRIBE_TELEGRAM) { + $queue->task_id = $task_id_telegram; + $queue->add_notification($arr_telegram); + // Add array of Telegram users to the notification queue list + } + + if (SUBSCRIBE_EMAIL) { + $queue->task_id = $task_id_email; + $queue->add_notification($arr_email); + // Add array of Email users to the notification queue list + } + }//end notify_subscribers() + + + /** + * Sends Telegram notification message using their web api. + * + * @param string $userID The Telegram userid to send to + * @param string $firstname The users firstname + * @param string $msg Body of message + * @return boolean true = Sent / False = failed + */ + public static function submit_queue_telegram($userID, $firstname, $msg) + { + // TODO Handle limitations (Max 30 different subscribers per second) + // TODO Error handling + $msg = sprintf($msg, $firstname); + + $tg_message = [ + 'text' => $msg, + 'chat_id' => $userID, + 'parse_mode' => 'HTML', + ]; + $json = @file_get_contents('https://api.telegram.org/bot'.TG_BOT_API_TOKEN.'/sendMessage?'.http_build_query($tg_message)); + + $response = json_decode($json, true); + + if (!is_array($response) || ! array_key_exists('ok', $response) || $response['ok'] != 1) { + return false; + } + + return true; + }//end submit_queue_telegram() + + + /** + * Sends email notifications to a subscriber. + * Function depends on Parsedown and Mailer class being loaded. + * + * @param string $userID The email address to send to + * @param string $uthkey Users token for managing subscription + * @return void + */ + public static function submit_queue_email($subscriber, $subject, $msg) + { + // TODO Error handling + $mailer = new Mailer(); + if (! $mailer->send_mail($subscriber, $subject, $msg, true)) { + return false; + } + + return true; + }//end submit_queue_email() + + + public function prepare_email() + { + $Parsedown = new Parsedown(); + $str_mail = file_get_contents('../templates/email_status_update.html'); + $str_mail = str_replace('%name%', NAME, $str_mail); + // $smtp_mail = str_replace("%email%", $userID, $smtp_mail); + $str_mail = str_replace('%url%', WEB_URL, $str_mail); + $str_mail = str_replace('%service%', $this->servicenames, $str_mail); + $str_mail = str_replace('%status%', $this->status, $str_mail); + $str_mail = str_replace('%time%', date('c', $this->time), $str_mail); + $str_mail = str_replace('%comment%', $Parsedown->setBreaksEnabled(true)->text($this->text), $str_mail); + // $str_mail = str_replace("%token%", $token, $str_mail); + $str_mail = str_replace('%service_status_update_from%', _('Service status update from'), $str_mail); + $str_mail = str_replace('%services_impacted%', _('Service(s) Impacted'), $str_mail); + $str_mail = str_replace('%status_label%', _('Status'), $str_mail); + $str_mail = str_replace('%time_label%', _('Time'), $str_mail); + $str_mail = str_replace('%manage_subscription%', _('Manage subscription'), $str_mail); + $str_mail = str_replace('%unsubscribe%', _('Unsubscribe'), $str_mail); + $str_mail = str_replace('%powered_by%', _('Powered by'), $str_mail); + + $subject = _('Status update from').' - '.NAME.' [ '.$this->status.' ]'; + + $val = []; + $val['subject'] = $subject; + $val['body'] = $str_mail; + return $val; + }//end prepare_email() + + + public function prepare_telegram() + { + $msg = _("Hi #s!\nThere is a status update for service(s): %s\nThe new status is: %s\nTitle: %s\n\n%s\n\nView online"); + $val['body'] = sprintf($msg, $this->servicenames, $this->status, $this->title, $this->text, WEB_URL); + return $val; + }//end prepare_telegram() +}//end class diff --git a/src/classes/queue.php b/src/classes/queue.php new file mode 100644 index 0000000..f53ec9d --- /dev/null +++ b/src/classes/queue.php @@ -0,0 +1,200 @@ + 1, + 'notify_email' => 2, + ]; + + public $all_status = [ + 'populating' => 1, + 'ready' => 2, + 'processing' => 3, + 'completed' => 4, + 'failed' => 5, + ]; + + + public function add_task() + { + global $mysqli; + $stmt = $mysqli->prepare('INSERT INTO queue_task (type_id, status, template_data1, template_data2, created_time, user_id) VALUES (?,?,?,?,?,?)'); + if (false === $stmt) { + // die('prepare() failed: ' . htmlspecialchars($mysqli->error)); + echo $mysqli->errno; + } + + // if ( false === $stmt ) { syslog(1, "Error :". $mysqli->error); } + $now = time(); + $res = $stmt->bind_param('iissii', $this->type_id, $this->status, $this->template_data1, $this->template_data2, $now, $this->user_id); + if (false === $res) { + echo 'error'; + die(); + } + + $stmt->execute(); + $query = $stmt->get_result(); + print $query; + $this->task_id = $mysqli->insert_id; + return $this->task_id; + }//end add_task() + + + /** + * Remove task from the queue + * + * @return void + */ + public static function delete_task($task_id) + { + global $mysqli; + $stmt = $mysqli->prepare('DELETE FROM queue_task WHERE id = ?'); + $stmt->bind_param('i', $task_id); + $stmt->execute(); + }//end delete_task() + + + /** + * Update status for given task + * + * @param integer $new_status The new current status of the task. Must be selected from the $all_status array. + * @return void + */ + public function set_task_status($new_status) + { + global $mysqli; + $stmt = $mysqli->prepare('UPDATE queue_task SET status = ? WHERE id = ?'); + $stmt->bind_param('ii', $new_status, $this->task_id); + $stmt->execute(); + $this->status = $new_status; + }//end set_task_status() + + + /** + * Add notification queue data for given task + * + * @param array $arr_data Array filled with subscriber_id + * @return void + */ + public function add_notification($arr_data) + { + global $mysqli; + + // Default status = 1, retres = 0, task_id = $this->task_id + // Build query manually since mysqli doesn't cater well for multi insert.. + $count = count($arr_data); + // Let's find number of elements + $counter = 0; + $query = ''; + $seperator = ','; + $sub_query = '(%d, %d, %d ,%d)%s'; + + foreach ($arr_data as $value) { + $counter++; + if ($counter == $count) { + $seperator = ''; + } //end if + + $query .= sprintf($sub_query, $this->task_id, 1, $value, 0, $seperator); + } + + $sql = 'INSERT INTO queue_notify (task_id, status, subscriber_id, retries) VALUES '.$query; + + $mysqli->query($sql); + + $this->set_task_status($this->all_status['ready']); + // Make task available for release + }//end add_notification() + + + public static function update_notification_retries($task_id, $subscriber_id) + { + global $mysqli; + $stmt = $mysqli->prepare('UPDATE queue_notify SET retries = retries+1 WHERE task_id = ? AND subscriber_id = ?'); + $stmt->bind_param('ii', $task_id, $subscriber_id); + $stmt->execute(); + }//end update_notification_retries() + + + public static function delete_notification($task_id, $subscriber_id) + { + global $mysqli; + $stmt = $mysqli->prepare('DELETE FROM queue_notify WHERE task_id = ? AND subscriber_id = ?'); + $stmt->bind_param('ii', $task_id, $subscriber_id); + $stmt->execute(); + }//end delete_notification() + + + // TODO: Fix max attempts for notifications + public static function process_queue() + { + global $mysqli; + $stmt = $mysqli->query('SELECT qn.id, qn.task_id, qn.status, qn.subscriber_id, qn.retries, sub.firstname, sub.userID, sub.token FROM queue_notify AS qn INNER JOIN subscribers AS sub ON qn.subscriber_id = sub.subscriberID WHERE qn.status NOT LIKE 2 AND sub.active=1'); + while ($result = $stmt->fetch_assoc()) { + $i = 2; + $stmt2 = $mysqli->prepare('SELECT * FROM queue_task WHERE id = ? AND status = ?'); + $stmt2->bind_param('ii', $result['task_id'], $i); + $stmt2->execute(); + $tmp = $stmt2->get_result(); + $result2 = $tmp->fetch_assoc(); + $typeID = $result2['type_id']; + + // Handle telegram + if ($typeID == 1) { + $msg = str_replace('#s', $result['firstname'], $result2['template_data2']); + if (! Notification::submit_queue_telegram($result['userID'], $result['firstname'], $msg)) { + self::update_notification_retries($result['task_id'], $result['subscriber_id']); + // Sent + } else { + self::delete_notification($result['task_id'], $result['subscriber_id']); + // Failed + } + } + + // Handle email + if ($typeID == 2) { + $msg = str_replace('%token%', $result['token'], $result2['template_data2']); + if (! Notification::submit_queue_email($result['userID'], $result2['template_data1'], $msg)) { + self::update_notification_retries($result['task_id'], $result['subscriber_id']); + // Sent + } else { + self::delete_notification($result['task_id'], $result['subscriber_id']); + // Failed + } + } + }//end while + + // Check if queue log is empty and if so delete the queue_task + $stmt = $mysqli->query('SELECT id, (SELECT COUNT(*) FROM queue_notify AS qn WHERE qn.task_id = queue_task.id) AS count FROM queue_task'); + while ($result = $stmt->fetch_assoc()) { + if ($result['count'] == 0) { + self::delete_task($result['id']); + } + } + }//end process_queue() +}//end class diff --git a/src/classes/service-group.php b/src/classes/service-group.php new file mode 100644 index 0000000..8908ca3 --- /dev/null +++ b/src/classes/service-group.php @@ -0,0 +1,178 @@ +id = $id; + $this->name = $name; + $this->description = $description; + $this->visibility_id = $visibility_id; + }//end __construct() + + + /** + * Returns id of this servicegroup + * + * @return integer id + */ + public function get_id() + { + return $this->id; + }//end get_id() + + + /** + * Returns name of this servicegroup + * + * @return string name + */ + public function get_name() + { + return $this->name; + }//end get_name() + + + /** + * Returns description of this servicegroup + * + * @return string description + */ + public function get_description() + { + return $this->description; + }//end get_description() + + + /** + * Processes submitted form and adds service unless problem is encountered, + * calling this is possible only for admin or higher rank. Also checks requirements + * for char limits. + * + * @return void + */ + public static function add() + { + global $user, $message; + if (strlen($_POST['group']) > 50) { + $message = _('Service group name is too long! Character limit is 50'); + return; + } elseif (strlen(trim($_POST['group'])) == 0) { + $message = _('Please enter name!'); + return; + } + + if ($user->get_rank() <= 1) { + global $mysqli; + $name = $_POST['group']; + $description = $_POST['description']; + $visibility_id = $_POST['visibility_id']; + $stmt = $mysqli->prepare('INSERT INTO services_groups VALUES(NULL,?,?,?)'); + $stmt->bind_param('ssi', $name, $description, $visibility_id); + $stmt->execute(); + $stmt->get_result(); + header('Location: '.WEB_URL.'/admin/?do=settings'); + } else { + $message = _("You don't have the permission to do that!"); + } + }//end add() + + + public static function edit() + { + global $user, $message; + if (strlen($_POST['group']) > 50) { + $message = _('Service group name is too long! Character limit is 50'); + return; + } elseif (strlen(trim($_POST['group'])) == 0) { + $message = _('Please enter name!'); + return; + } + + if ($user->get_rank() <= 1) { + global $mysqli; + $name = $_POST['group']; + $description = $_POST['description']; + $visibility_id = $_POST['visibility_id']; + $group_id = $_POST['id']; + $stmt = $mysqli->prepare('UPDATE services_groups SET name=?, description=?,visibility=? WHERE id LIKE ?'); + $stmt->bind_param('ssii', $name, $description, $visibility_id, $group_id); + $stmt->execute(); + $stmt->get_result(); + header('Location: '.WEB_URL.'/admin/?do=settings'); + } else { + $message = _("You don't have the permission to do that!"); + } + }//end edit() + + + /** + * Deletes this service - first checks if user has permission to do that. + * + * @return void + */ + public static function delete() + { + global $user, $message; + if ($user->get_rank() <= 1) { + global $mysqli; + $id = $_GET['delete']; + + $stmt = $mysqli->prepare('DELETE FROM services_groups WHERE id = ?'); + $stmt->bind_param('i', $id); + $stmt->execute(); + $query = $stmt->get_result(); + + $stmt = $mysqli->prepare('UPDATE services SET group_id = NULL WHERE group_id = ?'); + $stmt->bind_param('i', $id); + $stmt->execute(); + $query = $stmt->get_result(); + + header('Location: '.WEB_URL.'/admin/?do=settings'); + } else { + $message = _("You don't have the permission to do that!"); + } + }//end delete() + + + /** + * Get list of services groups. + * + * @return array $groups + */ + public static function get_groups() + { + global $mysqli; + $stmt = $mysqli->query('SELECT id, name FROM services_groups ORDER by name ASC'); + + $groups = []; + $groups[0] = ''; + while ($res = $stmt->fetch_assoc()) { + $groups[$res['id']] = $res['name']; + } + + return $groups; + }//end get_groups() +}//end class diff --git a/src/classes/service.php b/src/classes/service.php new file mode 100644 index 0000000..3042fca --- /dev/null +++ b/src/classes/service.php @@ -0,0 +1,285 @@ +id = $id; + $this->name = $name; + $this->description = $description; + $this->group_name = $group_name; + $this->status = $status; + }//end __construct() + + + /** + * Returns status of this service + * + * @return integer status + */ + public function get_status() + { + return $this->status; + }//end get_status() + + + /** + * Returns id of this service + * + * @return integer id + */ + public function get_id() + { + return $this->id; + }//end get_id() + + + /** + * Returns name of this service + * + * @return string name + */ + public function get_name() + { + return $this->name; + }//end get_name() + + + /** + * Returns description of this service + * + * @return string description + */ + public function get_description() + { + return $this->description; + }//end get_description() + + + /** + * Processes submitted form and adds service unless problem is encountered, + * calling this is possible only for admin or higher rank. Also checks requirements + * for char limits. + * + * @return void + */ + public static function add() + { + global $user, $message; + if (strlen($_POST['service']) > 50) { + $message = _('Service name is too long! Character limit is 50'); + return; + } elseif (strlen(trim($_POST['service'])) == 0) { + $message = _('Please enter name!'); + return; + } + + if ($user->get_rank() <= 1) { + global $mysqli; + $name = htmlspecialchars($_POST['service']); + $description = htmlspecialchars($_POST['description']); + $group_id = $_POST['group_id']; + $stmt = $mysqli->prepare('INSERT INTO services ( name, description, group_id ) VALUES ( ?, ?, ? )'); + $stmt->bind_param('ssi', $name, $description, $group_id); + $stmt->execute(); + $stmt->get_result(); + header('Location: '.WEB_URL.'/admin/?do=settings'); + } else { + $message = _("You don't have the permission to do that!"); + } + }//end add() + + + /** + * Processes submitted form and adds service unless problem is encountered, + * calling this is possible only for admin or higher rank. Also checks requirements + * for char limits. + * + * @return void + */ + public static function edit() + { + global $user, $message; + if (strlen($_POST['service']) > 50) { + $message = _('Service name is too long! Character limit is 50'); + return; + } elseif (strlen(trim($_POST['service'])) == 0) { + $message = _('Please enter name!'); + return; + } + + if ($user->get_rank() <= 1) { + global $mysqli; + $service_id = $_POST['id']; + $name = htmlspecialchars($_POST['service']); + $description = htmlspecialchars($_POST['description']); + $group_id = $_POST['group_id']; + $stmt = $mysqli->prepare('UPDATE services SET name=?, description=?, group_id=? WHERE id = ?'); + $stmt->bind_param('ssii', $name, $description, $group_id, $service_id); + $stmt->execute(); + $stmt->get_result(); + header('Location: '.WEB_URL.'/admin/?do=settings'); + } else { + $message = _("You don't have the permission to do that!"); + } + }//end edit() + + + /** + * Deletes this service - first checks if user has permission to do that. + * + * @return void + */ + public static function delete() + { + global $user, $message; + if ($user->get_rank() <= 1) { + global $mysqli; + $id = $_GET['delete']; + + $stmt = $mysqli->prepare('SELECT status_id as status, (SELECT count(*) FROM services_status as s WHERE s.status_id=status) as count FROM services_status WHERE service_id = ? GROUP BY status'); + $stmt->bind_param('i', $id); + $stmt->execute(); + $query = $stmt->get_result(); + + while ($res = $query->fetch_assoc()) { + if ($res['count'] == 1) { + Incident::delete($res['status']); + } + } + + $stmt = $mysqli->prepare('DELETE FROM services WHERE id = ?'); + $stmt->bind_param('i', $id); + $stmt->execute(); + $query = $stmt->get_result(); + + $stmt = $mysqli->prepare('DELETE FROM services_status WHERE service_id = ?'); + $stmt->bind_param('i', $id); + $stmt->execute(); + $query = $stmt->get_result(); + + header('Location: '.WEB_URL.'/admin/?do=settings'); + } else { + $message = _("You don't have the permission to do that!"); + }//end if + }//end delete() + + + /** + * Renders current status for services from passed array of services. + * + * @param Service[] $array array of services + * @return void + */ + public static function current_status($array) + { + global $all, $some, $classes; + $statuses = [ + 0, + 0, + 0, + 0, + ]; + $worst = 5; + + foreach ($array as $service) { + if ($service->status < $worst) { + $worst = $service->get_status(); + } + + $statuses[$service->get_status()]++; + } + + $result = '
            '; + + if ($statuses[$worst] == count($array)) { + $result .= $all[$worst]; + } else { + $result .= $some[$worst]; + } + + $result .= '
            '; + }//end current_status() + + /** + * Evaluates the group status + * + * @param Service[] $array array of services + * @return void + */ + public static function group_status($array) + { + $worst = 5; + + foreach ($array as $service) { + if ($service->status < $worst) { + $worst = $service->get_status(); + } + } + + return $worst; + }//end current_status() + + /** + * Renders this service. + * + * @param $boolGroup set to true if the groups name is to be rendered + * @return void + */ + public function render() + { + global $classes, $statuses; + + // Render the service status + echo '
          • '.$this->name.''; + // echo '
          • ' . $this->name . ''; + if (!empty($this->description)) { + echo ' '; + } + + if ($this->status != -1) { + ?>
            status]); ?>
            + '; + }//end render() + + + public function jsonSerialize() + { + global $statuses; + return [ + 'id' => $this->id, + 'name' => $this->name, + 'description' => $this->description, + 'status' => $this->status, + 'status_string' => $statuses[$this->status], + ]; + }//end jsonSerialize() +}//end class + diff --git a/src/classes/subscriber.php b/src/classes/subscriber.php new file mode 100644 index 0000000..4cf47f3 --- /dev/null +++ b/src/classes/subscriber.php @@ -0,0 +1,354 @@ +firstname = null; + $this->lastname = null; + $this->userID = ''; + $this->token = null; + $this->active = 0; + $this->typeID = null; + }//end __construct() + + + /** + * Gets authentcation token for specified subscriberID + * + * @param integer $subscriberID - specifies which subscriber we are looking up + * @param integer $typeID - specifies which type of subscription we are refering (1 = telegram, 2 = email) + * @return string $token - 32 bytes HEX string + */ + public function get_token($subscriberID, $typeID) + { + global $mysqli; + $stmt = $mysqli->prepare('SELECT token FROM subscribers WHERE subscriberID = ? and typeID=? and active = 1 LIMIT 1'); + $stmt->bind_param('ii', $subscriberID, $typeID); + $stmt->execute(); + $result = $stmt->get_result(); + if ($result->num_rows > 0) { + $row = $result->fetch_assoc(); + $this->token = $row['token']; + // $this->get_subscriber_by_token($this->token); + return $row['token']; + } + + return false; + }//end get_token() + + + public function get_subscriber_by_token($token) + { + global $mysqli; + $stmt = $mysqli->prepare('SELECT subscriberID FROM subscribers WHERE token=? and typeID=?'); + $stmt->bind_param('si', $token, $this->typeID); + $stmt->execute(); + $result = $stmt->get_result(); + if ($result->num_rows > 0) { + $row = $result->fetch_assoc(); + $this->id = $row['subscriberID']; + $this->populate(); + return true; + } + + return false; + }//end get_subscriber_by_token() + + + public function get_subscriber_by_userid($create = false) + { + global $mysqli; + $stmt = $mysqli->prepare('SELECT subscriberID FROM subscribers WHERE userID LIKE ? AND typeID = ? LIMIT 1'); + $stmt->bind_param('si', $this->userID, $this->typeID); + $stmt->execute(); + $result = $stmt->get_result(); + + if ($result->num_rows > 0) { + $row = $result->fetch_assoc(); + $this->id = $row['subscriberID']; + $this->populate(); + return $row['subscriberID']; + } else { + // User is not registered in DB, so add if $create = true + if ($create) { + $subscriber_id = $this->add($this->typeID, $this->userID, $this->active, $this->firstname, $this->lastname); + return $subscriber_id; + } + + return false; + } + }//end get_subscriber_by_userid() + + + public function populate() + { + global $mysqli; + $stmt = $mysqli->prepare('SELECT typeID, userID, firstname, lastname, token, active FROM subscribers WHERE subscriberID = ?'); + $stmt->bind_param('i', $this->id); + $stmt->execute(); + $result = $stmt->get_result(); + if ($result->num_rows > 0) { + $row = $result->fetch_assoc(); + $this->userID = $row['userID']; + $this->typeID = $row['typeID']; + $this->firstname = $row['firstname']; + $this->lastname = $row['lastname']; + $this->token = $row['token']; + $this->active = $row['active']; + return true; + } + + return false; + }//end populate() + + + public function add($typeID, $userID, $active = null, $firstname = null, $lastname = null) + { + global $mysqli; + $expireTime = strtotime('+2 hours'); + $updateTime = strtotime('now'); + $token = $this->generate_token(); + + $stmt = $mysqli->prepare('INSERT INTO subscribers (typeID, userID, firstname, lastname, token, active, expires, create_time) VALUES (?, ?, ?, ?, ?, ?, ?, ?)'); + $stmt->bind_param('issssiii', $typeID, $userID, $firstname, $lastname, $token, $active, $expireTime, $updateTime); + $stmt->execute(); + // $query = $stmt->get_result(); + $this->id = $mysqli->insert_id; + $this->typeID = $typeID; + $this->userID = $userID; + $this->token = $token; + $this->firstname = $firstname; + $this->lastname = $lastname; + $this->active = $active; + return $this->id; + }//end add() + + + public function update($subscriberID) + { + global $mysqli; + $updateTime = strtotime('now'); + $stmt = $mysqli->prepare('UPDATE subscribers SET update_time = ? WHERE subscriberID=?'); + $stmt->bind_param('ii', $updateTime, $subscriberID); + $stmt->execute(); + return true; + }//end update() + + + public function activate($subscriberID) + { + global $mysqli; + $updateTime = strtotime('now'); + + $stmt = $mysqli->prepare('UPDATE subscribers SET update_time = ?, expires = ? WHERE subscriberID = ?'); + $tmp = null; + $stmt->bind_param('iii', $updateTime, $tmp, $subscriberID); + $stmt->execute(); + return true; + }//end activate() + + + public function delete($subscriberID) + { + global $mysqli; + + $stmt = $mysqli->prepare('DELETE FROM services_subscriber WHERE subscriberIDFK = ?'); + $stmt->bind_param('i', $subscriberID); + $stmt->execute(); + // $query = $stmt->get_result(); + $stmt = $mysqli->prepare('DELETE FROM subscribers WHERE subscriberID = ?'); + $stmt->bind_param('i', $subscriberID); + $stmt->execute(); + // $query = $stmt->get_result(); + return true; + }//end delete() + + + public function check_userid_exist() + { + global $mysqli; + + $stmt = $mysqli->prepare('SELECT subscriberID, userID, token, active FROM subscribers WHERE typeID=? AND userID=? LIMIT 1'); + + $stmt->bind_param('is', $this->typeID, $this->userID); + $stmt->execute(); + $result = $stmt->get_result(); + + if ($result->num_rows > 0) { + $row = $result->fetch_assoc(); + $this->id = $row['subscriberID']; + $this->populate(); + return true; + } + + return false; + }//end check_userid_exist() + + + public function is_active_subscriber($token) + { + global $mysqli; + + $stmt = $mysqli->prepare('SELECT subscriberID, token, userID, active, expires FROM subscribers WHERE token LIKE ? LIMIT 1'); + $stmt->bind_param('s', $token); + $stmt->execute(); + $result = $stmt->get_result(); + + if ($result->num_rows > 0) { + $row = $result->fetch_assoc(); + } else { + // No data found, fail gently... + return false; + } + + // If account is not already active, check if we are within timeframe of exipre +2h + // and active if so, otherwise,delete account and return falsev + if ($row['active'] <> 1) { + // Calculate time range for when subscription need to be validated + $time_end = $row['expires']; + $time_start = ($time_end - (3600 * 2)); + // TODO - make this interval configurable via a config option + $time_now = time(); + + if (($time_now > $time_start) && ($time_now < $time_end)) { + // Timefram is within range, active user.. + $stmt2 = $mysqli->prepare('UPDATE subscribers SET active=1, expires=null WHERE subscriberID = ?'); + $stmt2->bind_param('i', $row['subscriberID']); + $stmt2->execute(); + $result = $stmt2->get_result(); + $this->active = 1; + $this->id = $row['subscriberID']; + $this->userID = $row['userID']; + $this->token = $row['token']; + return true; + } else { + // Timeframe outside of given scope -> delete account + $stmt2 = $mysqli->prepare('DELETE FROM subscribers WHERE subscriberID = ?'); + $stmt2->bind_param('i', $row['subscriberID']); + $stmt2->execute(); + $result = $stmt2->get_result(); + $this->active = 0; + return false; + } + }//end if + + // if we get here, account should already be active + $this->active = 1; + $this->id = $row['subscriberID']; + $this->userID = $row['userID']; + $this->token = $row['token']; + return true; + }//end is_active_subscriber() + + + /** + * Generate a new 64 byte token (32 bytes converted from bin2hex = 64 bytes) + * + * @return string token + */ + public function generate_token() + { + global $mysqli; + + if (function_exists('openssl_random_pseudo_bytes')) { + $token = openssl_random_pseudo_bytes(32); + // Generate a random string. + $token = bin2hex($token); + // Convert the binary data into hexadecimal representation. + } else { + // Use alternative token generator if openssl isn't available... + $token = make_alt_token(32, 32); + } + + // Make sure token doesn't already exist in db + $stmt = $mysqli->prepare('SELECT subscriberID FROM subscribers WHERE token LIKE ?'); + echo $mysqli->error; + $stmt->bind_param('s', $token); + $stmt->execute(); + $result = $stmt->get_result(); + if ($result->num_rows > 0) { + // token already exists, call self again + $token = $this->generate_token(); + } + + return $token; + }//end generate_token() + + + /** + * Alternative token generator if openssl_random_pseudo_bytes is not available + * Original code by jsheets at shadonet dot com from http://php.net/manual/en/function.mt-rand.php + * + * @params int min_length Minimum length of token + * @params int max_length Maximum length of token + * @return string token + */ + public function make_alt_token($min_length = 32, $max_length = 64) + { + $key = ''; + + // build range and shuffle range using ASCII table + for ($i = 0; $i <= 255; $i++) { + $range[] = chr($i); + } + + // shuffle our range 3 times + for ($i = 0; $i <= 3; $i++) { + shuffle($range); + } + + // loop for random number generation + for ($i = 0; $i < mt_rand($min_length, $max_length); $i++) { + $key .= $range[mt_rand(0, (count($range) - 1))]; + } + + $return = bin2hex($key); + + if (!empty($return)) { + return $return; + } else { + return 0; + } + }//end make_alt_token() + + + public function set_logged_in() + { + $_SESSION['subscriber_valid'] = true; + $_SESSION['subscriber_id'] = $this->id; + $_SESSION['subscriber_userid'] = $this->userID; + $_SESSION['subscriber_typeid'] = $this->typeID; + // email + $_SESSION['subscriber_token'] = $this->token; + }//end set_logged_in() + + + public function set_logged_off() + { + unset($_SESSION['subscriber_valid']); + unset($_SESSION['subscriber_userid']); + unset($_SESSION['subscriber_typeid']); + unset($_SESSION['subscriber_id']); + unset($_SESSION['subscriber_token']); + }//end set_logged_off() +}//end class diff --git a/src/classes/subscriptions.php b/src/classes/subscriptions.php new file mode 100644 index 0000000..effe7ca --- /dev/null +++ b/src/classes/subscriptions.php @@ -0,0 +1,104 @@ +prepare('INSERT INTO services_subscriber (subscriberIDFK, serviceIDFK) VALUES (?, ?)'); + $stmt->bind_param('ii', $userID, $service); + $stmt->execute(); + // $query = $stmt->get_result(); + return true; + }//end add() + + + public function remove($userID, $service) + { + global $mysqli; + + $stmt = $mysqli->prepare('DELETE FROM services_subscriber WHERE subscriberIDFK = ? AND serviceIDFK = ?'); + $stmt->bind_param('ii', $userID, $service); + $stmt->execute(); + // $query = $stmt->get_result(); + return true; + }//end remove() + + + function render_subscribed_services($typeID, $subscriberID, $userID, $token) + { + global $mysqli; + $stmt = $mysqli->prepare( + 'SELECT services.id, services.name, subscribers.subscriberID, subscribers.userID, subscribers.token + FROM services + LEFT JOIN services_subscriber ON services_subscriber.serviceIDFK = services.id + LEFT JOIN subscribers ON services_subscriber.subscriberIDFK = subscribers.subscriberID + WHERE subscribers.typeID = ? AND subscribers.subscriberID = ?' + ); + $stmt->bind_param('ii', $typeID, $subscriberID); + $stmt->execute(); + $query = $stmt->get_result(); + + $strNotifyType = _('E-mail Notification subscription'); + if ($typeID == 1) { + $strNotifyType = _('Telegram Notification subscription'); + } + + ?> +
            +
            +
            +

            +

            + +

            + +
            +
            +
            + '._('Your subscriptions').''; + echo '
            '; + $subs = []; + // Will be used to hold IDs of services already selected + if ($query->num_rows) { + while ($result = $query->fetch_assoc()) { + echo ' '.$result['name'].''; + $subs[] = $result['id']; + } + } else { + echo '
            '._('You do not currently subscribe to any services. Please add services from the list below.').'
            '; + } + + echo '
            '; + + echo '

            '._('Add new subscription').'

            '; + + // Prepare to query for unselect services. If none are selected, query for all + $subsExp = null; + if (count($subs) > 0) { + $subsExp = 'NOT IN ('.implode(',', $subs).')'; + } + + $query = $mysqli->query("SELECT services.id, services.name from services WHERE services.id $subsExp"); + echo '
            '; + if ($query->num_rows) { + while ($result = $query->fetch_assoc()) { + echo ' '.$result['name'].''; + } + } else { + echo '
            '._('No further services available for subscriptions.').'
            '; + } + + echo '
            '; + }//end render_subscribed_services() +}//end class diff --git a/src/classes/telegram.php b/src/classes/telegram.php new file mode 100644 index 0000000..3cd8d30 --- /dev/null +++ b/src/classes/telegram.php @@ -0,0 +1,95 @@ + $value) { + // $data_check_arr[] = $key . '=' . $value; + $data_check_arr[] = $key.'='.str_replace('https:/t', 'https://t', $value); + } + + sort($data_check_arr); + $data_check_string = implode("\n", $data_check_arr); + $secret_key = hash('sha256', TG_BOT_API_TOKEN, true); + $hash = hash_hmac('sha256', $data_check_string, $secret_key); + if (strcmp($hash, $check_hash) !== 0) { + throw new Exception('Data is NOT from Telegram'); + } + + if ((time() - $auth_data['auth_date']) > 86400) { + throw new Exception('Data is outdated'); + } + + return $auth_data; + }//end checkTelegramAuthorization() + + + /** + * Save telegram userdata + * + * Save the telegram user data in a cookie + * + * @return void + */ + function saveTelegramUserData($auth_data) + { + $auth_data_json = json_encode($auth_data); + setcookie('tg_user', $auth_data_json); + }//end saveTelegramUserData() + + + function get_telegram_subscriberid($user) + { + global $mysqli; + $stmt = $mysqli->prepare('SELECT subscriberID FROM subscribers WHERE typeID=1 AND userID LIKE ? LIMIT 1'); + $stmt->bind_param('s', $user); + $stmt->execute(); + $result = $stmt->get_result(); + if ($result->num_rows) { + $row = $result->fetch_assoc(); + $subscriberID = $row['subscriberID']; + return $subscriberID; + } + + return null; + // Return null on false + }//end get_telegram_subscriberid() +}//end class diff --git a/src/classes/token.php b/src/classes/token.php new file mode 100644 index 0000000..6d45700 --- /dev/null +++ b/src/classes/token.php @@ -0,0 +1,84 @@ +prepare('INSERT INTO tokens VALUES(?, ?, ?, ?)'); + $stmt->bind_param('siis', $token, $id, $expire, $data); + $stmt->execute(); + $stmt->get_result(); + return $token; + }//end add() + + + /** + * Checks whether token exists in the database and has not expired. + * + * @param string $token + * @param integer $id user ID + * @param string $data + * @return integer count of results in database + */ + public static function validate($token, $id, $data) + { + global $mysqli; + $time = time(); + $stmt = $mysqli->prepare('SELECT count(*) as count FROM tokens WHERE token = ? AND user = ? AND expire>=? AND data LIKE ?'); + $stmt->bind_param('siis', $token, $id, $time, $data); + $stmt->execute(); + $query = $stmt->get_result(); + return $query->fetch_assoc()['count']; + }//end validate() + + + /** + * Returns token data + * + * @param string $token + * @param integer $id user ID + * @return string data + */ + public static function get_data($token, $id) + { + global $mysqli; + $stmt = $mysqli->prepare('SELECT data as count FROM tokens WHERE token = ? AND user = ?'); + $stmt->bind_param('si', $token, $id); + $stmt->execute(); + $query = $stmt->get_result(); + return $query->fetch_assoc()['data']; + }//end get_data() + + + /** + * Deletes token. + * + * @param string $token + * @return void + */ + public static function delete($token) + { + global $mysqli; + $time = time(); + $stmt = $mysqli->prepare('DELETE FROM tokens WHERE token = ? OR expirebind_param('sd', $token, $time); + $stmt->execute(); + $stmt->get_result(); + }//end delete() +}//end class diff --git a/src/classes/user.php b/src/classes/user.php new file mode 100644 index 0000000..fd52327 --- /dev/null +++ b/src/classes/user.php @@ -0,0 +1,774 @@ +prepare('SELECT * FROM users WHERE id=?'); + $stmt->bind_param('d', $id); + $stmt->execute(); + $query = $stmt->get_result(); + + if (!$query->num_rows) { + throw new Exception("User doesn't exist."); + return; + } + + $result = $query->fetch_array(); + $this->id = $id; + $this->active = $result['active']; + $this->name = $result['name']; + $this->email = $result['email']; + $this->surname = $result['surname']; + $this->username = $result['username']; + $this->rank = $result['permission']; + }//end __construct() + + + /** + * Returns username of this user + * + * @return string username + */ + public function get_username() + { + return $this->username; + }//end get_username() + + + /** + * Returns whether this user is active + * + * @return boolean user active status + */ + public function is_active() + { + return $this->active; + }//end is_active() + + + /** + * Returns rank of this user + * + * @return integer rank + */ + public function get_rank() + { + return $this->rank; + }//end get_rank() + + + /** + * Returns full name of this user + * + * @return string name in "Name Surname" format + */ + public function get_name() + { + return $this->name.' '.$this->surname; + }//end get_name() + + + /** + * Toggles active status of this user. First checks if the user + * making the change has permission to do that. + * + * @return void + */ + public function toggle() + { + global $mysqli, $message, $user; + + $id = $_GET['id']; + if ($this->id != $_SESSION['user'] && $user->get_rank() <= 1 && ($user->get_rank() < $this->rank)) { + $stmt = $mysqli->prepare('UPDATE users SET active = !active WHERE id=?'); + $stmt->bind_param('i', $this->id); + $stmt->execute(); + $stmt->close(); + header('Location: '.WEB_URL.'/admin/?do=user&id='.$id); + } else { + $message = _("You don't have the permission to do that!"); + } + }//end toggle() + + + /** + * Processes submitted form and adds user unless problem is encountered, + * calling this is possible only for Superadmin (other ranks cannot add users) + * or when the installation script is being run. Also checks requirements + * for username and email being unique and char limits. + * + * @return void + */ + public static function add() + { + global $user, $message, $mysqli; + if (INSTALL_OVERRIDE || $user->get_rank() == 0) { + if (strlen(trim($_POST['name'])) == 0) { + $messages[] = _('Name'); + } + + if (strlen(trim($_POST['surname'])) == 0) { + $messages[] = _('Surname'); + } + + if (strlen(trim($_POST['email'])) == 0) { + $messages[] = _('Email'); + } + + if (strlen(trim($_POST['password'])) == 0) { + $messages[] = _('Password'); + } + + if (!isset($_POST['permission'])) { + $messages[] = _('Rank'); + } + + if (isset($messages)) { + $message = 'Please enter '.implode(', ', $messages); + return; + } + + $name = $_POST['name']; + $surname = $_POST['surname']; + $username = $_POST['username']; + $email = $_POST['email']; + $pass = $_POST['password']; + + if (!filter_var($email, FILTER_VALIDATE_EMAIL)) { + $message = 'Invalid email!'; + return; + } + + $variables = []; + if (strlen($name) > 50) { + $variables[] = 'name: 50'; + } + + if (strlen($surname) > 50) { + $variables[] = 'surname: 50'; + } + + if (strlen($username) > 50) { + $variables[] = 'username: 50'; + } + + if (strlen($email) > 60) { + $variables[] = 'email: 60'; + } + + if (!empty($variables)) { + $message = _('Please mind the following character limits: '); + $message .= implode(', ', $variables); + return; + } + + $salt = uniqid(mt_rand(), true); + $hash = hash('sha256', $pass.$salt); + $permission = $_POST['permission']; + + $stmt = $mysqli->prepare('INSERT INTO users values (NULL, ?, ?, ?, ?, ?, ?, ?, 1)'); + $stmt->bind_param('ssssssi', $email, $username, $name, $surname, $hash, $salt, $permission); + $stmt->execute(); + + if ($stmt->affected_rows == 0) { + $message = _('Username or email already used'); + return; + } + + $to = $email; + $subject = _('User account created').' - '.NAME; + $msg = sprintf(_('Hi %s!
            '.'Your account has been created. You can login with your email address at %s with password %s - please change it as soon as possible.'), $name.' '.$surname, WEB_URL.'/admin', WEB_URL.'/admin', $pass); + $headers = 'Content-Type: text/html; charset=utf-8 '.PHP_EOL; + $headers .= 'MIME-Version: 1.0 '.PHP_EOL; + $headers .= 'From: '.MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; + $headers .= 'Reply-To: '.MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; + + mail($to, $subject, $msg, $headers); + if (!INSTALL_OVERRIDE) { + header('Location: '.WEB_URL.'/admin/?do=settings'); + } + } else { + $message = _("You don't have the permission to do that!"); + }//end if + }//end add() + + + /** + * Processes submitted form and logs user in, unless the user is deactivated or wrong + * password or email has been submitted. The script doesn't let anyone know which + * field was wrong as it is not possible to verify email address from outside admin panel, + * so this actually helps with security :) + * + * @return void + */ + public static function login() + { + global $message, $mysqli; + if (!isset($_POST['email']) && !isset($_POST['email'])) { + return; + } + + if ((!isset($_POST['email']) || !isset($_POST['email']))) { + $message = _('Please fill in your email and password!'); + return; + } + + $email = $_POST['email']; + $pass = $_POST['pass']; + + $stmt = $mysqli->prepare('SELECT id,password_salt as salt,active FROM users WHERE email=?'); + $stmt->bind_param('s', $email); + $stmt->execute(); + $query = $stmt->get_result(); + + if ($query->num_rows < 1) { + $message = _('Wrong email or password'); + return; + } + + $result = $query->fetch_assoc(); + $salt = $result['salt']; + $id = $result['id']; + $active = $result['active']; + + if (!$active) { + $message = _('Your account has been disabled. Please contact administrator.'); + return; + } + + $hash = hash('sha256', $pass.$salt); + $stmt = $mysqli->prepare('SELECT count(*) as count FROM users WHERE id=? AND password_hash=?'); + $stmt->bind_param('is', $id, $hash); + $stmt->execute(); + $query = $stmt->get_result(); + + if (!$query->fetch_assoc()['count']) { + $message = _('Wrong email or password'); + return; + } + + if (isset($_POST['remember']) && $_POST['remember']) { + $year = strtotime('+356 days', time()); + $token = Token::add($id, 'remember', $year); + setcookie('token', $token, $year, '/'); + setcookie('user', $id, $year, '/'); + } + + $_SESSION['user'] = $id; + header('Location: '.WEB_URL.'/admin'); + }//end login() + + + /** + * Checks whether token is valid (this means is in database and associated + * with the user) and sets session data if it is, so user remains logged in. + * The script deletes the token either way. + * + * @return void + */ + public static function restore_session() + { + global $message; + $id = $_COOKIE['user']; + $token = $_COOKIE['token']; + + if (Token::validate($token, $id, 'remember')) { + $year = strtotime('+356 days', time()); + unset($_COOKIE['token']); + $_SESSION['user'] = $id; + $new_token = Token::add($id, 'remember', $year); + setcookie('token', $new_token, $year, '/'); + setcookie('user', $id, $year, '/'); + } else { + unset($_COOKIE['user']); + unset($_COOKIE['token']); + setcookie('user', null, -1, '/'); + setcookie('token', null, -1, '/'); + $message = _('Invalid token detected, please login again!'); + } + + Token::delete($token); + }//end restore_session() + + + /** + * Renders settings for this user so it can be displayed in admin panel. + * + * @return void + */ + public function render_user_settings() + { + global $permissions, $user; + ?> +
            +
            <?php echo _('Profile picture'); ?>
            +
            + id == $_SESSION['user'] || $user->get_rank() < 1) { + ?> +
            +
            +
            +
            + + +
            +
            + name, ENT_QUOTES); ?>> + surname, ENT_QUOTES); ?>> +
            +
            +
            +
            + +
            +
            + +

            name.' '.$this->surname; ?>

            + +
            +
            +
            +
            +
            +
            + id == $_SESSION['user'] || $user->get_rank() < 1) { + ?> +
            + + + + +
            + + username.' '; + if ($user->get_rank() >= 1) { + echo ""; + } + } + ?> +
            +
            +
            + +
            +
            +
            +
            get_rank() == 0 && $this->id != $_SESSION['user']) { ?> +
            + + +
            + rank]; + } + ?> +
            +
            +
            + + id == $_SESSION['user'] || $user->get_rank() < 1) { ?> +
            +
            +
            Email
            +
            +
            + + + + +
            +
            +
            +
            + +
            +
            +
            + email; ?> +
            +
            + id == $_SESSION['user']) { + ?> + +
            +
            +
            +
            + + + + + + + +
            +
            +
            + id != $_SESSION['user'] && $user->get_rank() <= 1 && ($user->get_rank() < $this->rank)) { + ?> +
            +
            +
            + active) { + echo ''._('Deactivate user').''; + } else { + echo ''._('Activate user').''; + } + ?> +
            +
            + id; + + $stmt = $mysqli->prepare('SELECT count(*) FROM users WHERE username LIKE ?'); + $stmt->bind_param('s', $_POST['username']); + $stmt->execute(); + if ($stmt->num_rows > 0) { + $message = _('This username is already taken.'); + return; + } + + $stmt->close(); + + if ($_SESSION['user'] != $id && $user->get_rank() > 0) { + $message = _('Cannot change username of other users!'); + } else { + $stmt = $mysqli->prepare('UPDATE users SET username = ? WHERE id=?'); + $stmt->bind_param('si', $_POST['username'], $id); + $stmt->execute(); + $stmt->close(); + header('Location: '.WEB_URL.'/admin/?do=user&id='.$id); + } + }//end change_username() + + + /** + * Changes name and surname of user by POST[ID]. + * + * @return void + */ + public function change_name() + { + global $mysqli, $message, $user; + if (strlen(trim($_POST['name'])) == 0) { + $messages[] = _('Name'); + } + + if (strlen(trim($_POST['surname'])) == 0) { + $messages[] = _('Surname'); + } + + if (!empty($messages)) { + $message = 'Please enter '.implode(', ', $messages); + return; + } + + $id = $this->id; + + if ($_SESSION['user'] != $id && $user->get_rank() > 0) { + $message = _('Cannot change names of other users!'); + } else { + $stmt = $mysqli->prepare('UPDATE users SET `name` = ?, `surname` = ? WHERE id=?'); + $stmt->bind_param('ssi', $_POST['name'], $_POST['surname'], $id); + $stmt->execute(); + $stmt->close(); + header('Location: '.WEB_URL.'/admin/?do=user&id='.$id); + } + }//end change_name() + + + /** + * Changes user password and deletes all remember tokens so all other sessions + * won't stay logged in without knowing new pass. Uses token when reseting password. + * + * @param string $token + * @return void + */ + public function change_password($token = false) + { + global $mysqli, $message; + $id = $this->id; + if ($_POST['password'] != $_POST['password_repeat']) { + $message = _('Passwords do not match!'); + return; + } + + if (!$token) { + if ($_SESSION['user'] != $id) { + $message = _('Cannot change password of other users!'); + } else { + $stmt = $mysqli->prepare('SELECT password_salt as salt FROM users WHERE id=?'); + $stmt->bind_param('i', $id); + $stmt->execute(); + $query = $stmt->get_result(); + $result = $query->fetch_assoc(); + + $salt = $result['salt']; + $pass = $_POST['old_password']; + $hash = hash('sha256', $pass.$salt); + + $stmt = $mysqli->prepare('SELECT count(*) as count FROM users WHERE id=? AND password_hash = ?'); + $stmt->bind_param('is', $id, $hash); + $stmt->execute(); + + if ($stmt->get_result()->fetch_assoc()['count']) { + $pass = $_POST['password']; + $hash = hash('sha256', $pass.$salt); + $stmt = $mysqli->prepare('UPDATE users SET password_hash = ? WHERE id=?'); + $stmt->bind_param('si', $hash, $id); + $stmt->execute(); + $stmt->close(); + + $stmt = $mysqli->prepare("DELETE FROM tokens WHERE user = ? AND data = 'remember'"); + $stmt->bind_param('d', $id); + $stmt->execute(); + $stmt->get_result(); + + self::logout(); + } else { + $message = _('Wrong password!'); + } + }//end if + } else { + if (Token::validate($token, $id, 'passwd')) { + $stmt = $mysqli->prepare('SELECT password_salt as salt FROM users WHERE id=?'); + $stmt->bind_param('i', $id); + $stmt->execute(); + $query = $stmt->get_result(); + $result = $query->fetch_assoc(); + + $salt = $result['salt']; + $pass = $_POST['password']; + $hash = hash('sha256', $pass.$salt); + + $stmt = $mysqli->prepare('UPDATE users SET password_hash = ? WHERE id=?'); + $stmt->bind_param('si', $hash, $id); + $stmt->execute(); + $stmt->close(); + + $stmt = $mysqli->prepare("DELETE FROM tokens WHERE user = ? AND data = 'remember'"); + $stmt->bind_param('d', $id); + $stmt->execute(); + $stmt->get_result(); + } else { + $message = _('Invalid token detected, please retry your request from start!'); + }//end if + + Token::delete($token); + }//end if + }//end change_password() + + + /** + * Sends email with link for password reset, link is token protected and valid only once. + * + * @return void + */ + public static function password_link() + { + global $mysqli; + $email = $_POST['email']; + + $stmt = $mysqli->prepare('SELECT id FROM users WHERE email=?'); + $stmt->bind_param('s', $email); + $stmt->execute(); + $query = $stmt->get_result(); + + $id = $query->fetch_assoc()['id']; + $time = strtotime('+1 day', time()); + + $token = Token::add($id, 'passwd', $time); + + $link = WEB_URL."/admin/?do=lost-password&id=$id&token=$token"; + $to = $email; + $user = new User($id); + $subject = _('Reset password').' - '.NAME; + $msg = sprintf(_("Hi %s!
            Below you will find link to change your password. The link is valid for 24hrs. If you didn't request this, feel free to ignore it.

            RESET PASSWORD

            If the link doesn't work, copy & paste it into your browser:
            %s"), $user->get_name(), $link, $link); + $headers = 'Content-Type: text/html; charset=utf-8 '.PHP_EOL; + $headers .= 'MIME-Version: 1.0 '.PHP_EOL; + $headers .= 'From: '.MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; + $headers .= 'Reply-To: '.MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; + + mail($to, $subject, $msg, $headers); + }//end password_link() + + + /** + * Sends email with link for email change confirmation (security reasons), link is token protected and valid only once. + * + * @return void + */ + public function email_link() + { + global $user, $mysqli; + + $email = $_POST['email']; + $id = $this->id; + + if ($user->get_rank() < 1 && $id != $_SESSION['user']) { + $stmt = $mysqli->prepare('UPDATE users SET email = ? WHERE id=?'); + $stmt->bind_param('sd', $email, $id); + $stmt->execute(); + $stmt->get_result(); + header('Location: '.WEB_URL.'/admin/?do=user&id='.$id); + return; + } + + $time = strtotime('+1 day', time()); + + $token = Token::add($id, 'email;$email', $time); + + $link = WEB_URL."/admin/?do=change-email&id=$id&token=$token"; + $to = $email; + $subject = _('Email change').' - '.NAME; + $msg = sprintf(_("Hi %s!
            Below you will find link to change your email. The link is valid for 24hrs. If you didn't request this, feel free to ignore it.

            CHANGE EMAIL

            If the link doesn't work, copy & paste it into your browser:
            %s"), $user->get_name(), $link, $link); + $headers = 'Content-Type: text/html; charset=utf-8 '.PHP_EOL; + $headers .= 'MIME-Version: 1.0 '.PHP_EOL; + $headers .= 'From: '.MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; + $headers .= 'Reply-To: '.MAILER_NAME.' <'.MAILER_ADDRESS.'>'.PHP_EOL; + + mail($to, $subject, $msg, $headers); + return _('Confirmation email sent!'); + }//end email_link() + + + /** + * Changes email. + * + * @return void + */ + public function change_email() + { + global $mysqli, $message; + $token = $_GET['token']; + $id = $_GET['id']; + + if (Token::validate($token, $id, 'email;%')) { + $data = explode(';', Token::get_data($token, $id)); + + $email = $data[1]; + + $stmt = $mysqli->prepare('UPDATE users SET email = ? WHERE id=?'); + $stmt->bind_param('sd', $email, $id); + $stmt->execute(); + $stmt->get_result(); + Token::delete($token); + header('Location: '.WEB_URL.'/admin/'); + } else { + $message = _('Invalid token detected, please retry your request from start!'); + } + + Token::delete($token); + }//end change_email() + + + /** + * Logs current user out. + * + * @return void + */ + public static function logout() + { + session_unset(); + if (isset($_COOKIE['token'])) { + $token = $_COOKIE['token']; + Token::delete($token); + unset($_COOKIE['user']); + unset($_COOKIE['token']); + setcookie('user', null, -1, '/'); + setcookie('token', null, -1, '/'); + } + + header('Location: '.WEB_URL.'/admin'); + }//end logout() + + + /** + * Changes permissions of current user - only super admin can do this, so it checks permission first. + * + * @return void + */ + public function change_permission() + { + global $mysqli, $message, $user; + if ($user->get_rank() == 0) { + $permission = $_POST['permission']; + $id = $_GET['id']; + $stmt = $mysqli->prepare('UPDATE users SET permission=? WHERE id=?'); + $stmt->bind_param('si', $permission, $id); + $stmt->execute(); + header('Location: '.WEB_URL.'/admin/?do=user&id='.$id); + } else { + $message = _("You don't have permission to do that!"); + } + }//end change_permission() +}//end class + diff --git a/src/composer.json b/src/composer.json new file mode 100644 index 0000000..bb6fdca --- /dev/null +++ b/src/composer.json @@ -0,0 +1,6 @@ +{ + "require": { + "erusev/parsedown": "^1.7", + "true/punycode": "~2.0" + } +} diff --git a/src/composer.lock b/src/composer.lock new file mode 100644 index 0000000..412850d --- /dev/null +++ b/src/composer.lock @@ -0,0 +1,199 @@ +{ + "_readme": [ + "This file locks the dependencies of your project to a known state", + "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", + "This file is @generated automatically" + ], + "content-hash": "9de913b5a2a79e4be8c983c1cf5bcea1", + "packages": [ + { + "name": "erusev/parsedown", + "version": "1.7.4", + "source": { + "type": "git", + "url": "https://github.com/erusev/parsedown.git", + "reference": "cb17b6477dfff935958ba01325f2e8a2bfa6dab3" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/erusev/parsedown/zipball/cb17b6477dfff935958ba01325f2e8a2bfa6dab3", + "reference": "cb17b6477dfff935958ba01325f2e8a2bfa6dab3", + "shasum": "" + }, + "require": { + "ext-mbstring": "*", + "php": ">=5.3.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.8.35" + }, + "type": "library", + "autoload": { + "psr-0": { + "Parsedown": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Emanuil Rusev", + "email": "hello@erusev.com", + "homepage": "http://erusev.com" + } + ], + "description": "Parser for Markdown.", + "homepage": "http://parsedown.org", + "keywords": [ + "markdown", + "parser" + ], + "support": { + "issues": "https://github.com/erusev/parsedown/issues", + "source": "https://github.com/erusev/parsedown/tree/1.7.x" + }, + "time": "2019-12-30T22:54:17+00:00" + }, + { + "name": "symfony/polyfill-mbstring", + "version": "v1.23.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-mbstring.git", + "reference": "9174a3d80210dca8daa7f31fec659150bbeabfc6" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9174a3d80210dca8daa7f31fec659150bbeabfc6", + "reference": "9174a3d80210dca8daa7f31fec659150bbeabfc6", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "suggest": { + "ext-mbstring": "For best performance" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.23-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Polyfill\\Mbstring\\": "" + }, + "files": [ + "bootstrap.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for the Mbstring extension", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "mbstring", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.23.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2021-05-27T12:26:48+00:00" + }, + { + "name": "true/punycode", + "version": "v2.1.1", + "source": { + "type": "git", + "url": "https://github.com/true/php-punycode.git", + "reference": "a4d0c11a36dd7f4e7cd7096076cab6d3378a071e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/true/php-punycode/zipball/a4d0c11a36dd7f4e7cd7096076cab6d3378a071e", + "reference": "a4d0c11a36dd7f4e7cd7096076cab6d3378a071e", + "shasum": "" + }, + "require": { + "php": ">=5.3.0", + "symfony/polyfill-mbstring": "^1.3" + }, + "require-dev": { + "phpunit/phpunit": "~4.7", + "squizlabs/php_codesniffer": "~2.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "TrueBV\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Renan Gonçalves", + "email": "renan.saddam@gmail.com" + } + ], + "description": "A Bootstring encoding of Unicode for Internationalized Domain Names in Applications (IDNA)", + "homepage": "https://github.com/true/php-punycode", + "keywords": [ + "idna", + "punycode" + ], + "support": { + "issues": "https://github.com/true/php-punycode/issues", + "source": "https://github.com/true/php-punycode/tree/master" + }, + "time": "2016-11-16T10:37:54+00:00" + } + ], + "packages-dev": [], + "aliases": [], + "minimum-stability": "stable", + "stability-flags": [], + "prefer-stable": false, + "prefer-lowest": false, + "platform": [], + "platform-dev": [], + "plugin-api-version": "2.1.0" +} diff --git a/config.php.template b/src/config.php.template similarity index 97% rename from config.php.template rename to src/config.php.template index cc293d8..4580217 100644 --- a/config.php.template +++ b/src/config.php.template @@ -19,6 +19,8 @@ // Vojtěch Sajdl - Yigit Kerem Oktay - Thomas Nilsen - jhuesser /**************************************************************************************/ session_start(); +require 'vendor/autoload.php'; + //Start editing here //define("NAME", "##name##"); //Website name //define("TITLE", "##title##"); @@ -31,6 +33,7 @@ define("POLICY_MAIL", "##policy_mail##"); //contact email in policy define("POLICY_PHONE", "##policy_phone##"); define("WHO_WE_ARE","##who_we_are##"); define("POLICY_URL","##policy_url##"); +define("IMPRINT_URL","##imprint_url##"); define("INSTALL_OVERRIDE", false); define("DEFAULT_LANGUAGE", "en_GB"); define("CUSTOM_LOGO_URL",""); // This will use the default logo if left empty diff --git a/create-server-config.php b/src/create-server-config.php similarity index 55% rename from create-server-config.php rename to src/create-server-config.php index c3130da..a711914 100644 --- a/create-server-config.php +++ b/src/create-server-config.php @@ -7,17 +7,16 @@ // This is needed because some hosts do not either unzip hidden files // or neither GitHub puts that file inside the zips. /********************************************************************/ -if(stripos($_SERVER['SERVER_SOFTWARE'],'apache')!== false){ -$f = fopen(".htaccess", "a+"); -$f2 = fopen("ApacheHtaccess","r"); -fwrite($f, fread($f2, filesize("ApacheHtaccess"))); -fclose($f); -fclose($f2); +if (stripos($_SERVER['SERVER_SOFTWARE'], 'apache')!== false) { + $f = fopen(".htaccess", "a+"); + $f2 = fopen("ApacheHtaccess", "r"); + fwrite($f, fread($f2, filesize("ApacheHtaccess"))); + fclose($f); + fclose($f2); } else { -$f = fopen("web.config", "a+"); -$f2 = fopen("IISWebConfig","r"); -fwrite($f, fread($f2, filesize("IISWebConfig"))); -fclose($f); -fclose($f2); + $f = fopen("web.config", "a+"); + $f2 = fopen("IISWebConfig", "r"); + fwrite($f, fread($f2, filesize("IISWebConfig"))); + fclose($f); + fclose($f2); } -?> diff --git a/src/css/bootstrap-icons.css b/src/css/bootstrap-icons.css new file mode 100644 index 0000000..41721c9 --- /dev/null +++ b/src/css/bootstrap-icons.css @@ -0,0 +1,1390 @@ +@font-face { + font-family: "bootstrap-icons"; + src: url("../fonts/bootstrap-icons.woff2?856008caa5eb66df68595e734e59580d") format("woff2"), +url("../fonts/bootstrap-icons.woff?856008caa5eb66df68595e734e59580d") format("woff"); +} + +[class^="bi-"]::before, +[class*=" bi-"]::before { + display: inline-block; + font-family: bootstrap-icons !important; + font-style: normal; + font-weight: normal !important; + font-variant: normal; + text-transform: none; + line-height: 1; + vertical-align: -.125em; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +.bi-alarm-fill::before { content: "\f101"; } +.bi-alarm::before { content: "\f102"; } +.bi-align-bottom::before { content: "\f103"; } +.bi-align-center::before { content: "\f104"; } +.bi-align-end::before { content: "\f105"; } +.bi-align-middle::before { content: "\f106"; } +.bi-align-start::before { content: "\f107"; } +.bi-align-top::before { content: "\f108"; } +.bi-alt::before { content: "\f109"; } +.bi-app-indicator::before { content: "\f10a"; } +.bi-app::before { content: "\f10b"; } +.bi-archive-fill::before { content: "\f10c"; } +.bi-archive::before { content: "\f10d"; } +.bi-arrow-90deg-down::before { content: "\f10e"; } +.bi-arrow-90deg-left::before { content: "\f10f"; } +.bi-arrow-90deg-right::before { content: "\f110"; } +.bi-arrow-90deg-up::before { content: "\f111"; } +.bi-arrow-bar-down::before { content: "\f112"; } +.bi-arrow-bar-left::before { content: "\f113"; } +.bi-arrow-bar-right::before { content: "\f114"; } +.bi-arrow-bar-up::before { content: "\f115"; } +.bi-arrow-clockwise::before { content: "\f116"; } +.bi-arrow-counterclockwise::before { content: "\f117"; } +.bi-arrow-down-circle-fill::before { content: "\f118"; } +.bi-arrow-down-circle::before { content: "\f119"; } +.bi-arrow-down-left-circle-fill::before { content: "\f11a"; } +.bi-arrow-down-left-circle::before { content: "\f11b"; } +.bi-arrow-down-left-square-fill::before { content: "\f11c"; } +.bi-arrow-down-left-square::before { content: "\f11d"; } +.bi-arrow-down-left::before { content: "\f11e"; } +.bi-arrow-down-right-circle-fill::before { content: "\f11f"; } +.bi-arrow-down-right-circle::before { content: "\f120"; } +.bi-arrow-down-right-square-fill::before { content: "\f121"; } +.bi-arrow-down-right-square::before { content: "\f122"; } +.bi-arrow-down-right::before { content: "\f123"; } +.bi-arrow-down-short::before { content: "\f124"; } +.bi-arrow-down-square-fill::before { content: "\f125"; } +.bi-arrow-down-square::before { content: "\f126"; } +.bi-arrow-down-up::before { content: "\f127"; } +.bi-arrow-down::before { content: "\f128"; } +.bi-arrow-left-circle-fill::before { content: "\f129"; } +.bi-arrow-left-circle::before { content: "\f12a"; } +.bi-arrow-left-right::before { content: "\f12b"; } +.bi-arrow-left-short::before { content: "\f12c"; } +.bi-arrow-left-square-fill::before { content: "\f12d"; } +.bi-arrow-left-square::before { content: "\f12e"; } +.bi-arrow-left::before { content: "\f12f"; } +.bi-arrow-repeat::before { content: "\f130"; } +.bi-arrow-return-left::before { content: "\f131"; } +.bi-arrow-return-right::before { content: "\f132"; } +.bi-arrow-right-circle-fill::before { content: "\f133"; } +.bi-arrow-right-circle::before { content: "\f134"; } +.bi-arrow-right-short::before { content: "\f135"; } +.bi-arrow-right-square-fill::before { content: "\f136"; } +.bi-arrow-right-square::before { content: "\f137"; } +.bi-arrow-right::before { content: "\f138"; } +.bi-arrow-up-circle-fill::before { content: "\f139"; } +.bi-arrow-up-circle::before { content: "\f13a"; } +.bi-arrow-up-left-circle-fill::before { content: "\f13b"; } +.bi-arrow-up-left-circle::before { content: "\f13c"; } +.bi-arrow-up-left-square-fill::before { content: "\f13d"; } +.bi-arrow-up-left-square::before { content: "\f13e"; } +.bi-arrow-up-left::before { content: "\f13f"; } +.bi-arrow-up-right-circle-fill::before { content: "\f140"; } +.bi-arrow-up-right-circle::before { content: "\f141"; } +.bi-arrow-up-right-square-fill::before { content: "\f142"; } +.bi-arrow-up-right-square::before { content: "\f143"; } +.bi-arrow-up-right::before { content: "\f144"; } +.bi-arrow-up-short::before { content: "\f145"; } +.bi-arrow-up-square-fill::before { content: "\f146"; } +.bi-arrow-up-square::before { content: "\f147"; } +.bi-arrow-up::before { content: "\f148"; } +.bi-arrows-angle-contract::before { content: "\f149"; } +.bi-arrows-angle-expand::before { content: "\f14a"; } +.bi-arrows-collapse::before { content: "\f14b"; } +.bi-arrows-expand::before { content: "\f14c"; } +.bi-arrows-fullscreen::before { content: "\f14d"; } +.bi-arrows-move::before { content: "\f14e"; } +.bi-aspect-ratio-fill::before { content: "\f14f"; } +.bi-aspect-ratio::before { content: "\f150"; } +.bi-asterisk::before { content: "\f151"; } +.bi-at::before { content: "\f152"; } +.bi-award-fill::before { content: "\f153"; } +.bi-award::before { content: "\f154"; } +.bi-back::before { content: "\f155"; } +.bi-backspace-fill::before { content: "\f156"; } +.bi-backspace-reverse-fill::before { content: "\f157"; } +.bi-backspace-reverse::before { content: "\f158"; } +.bi-backspace::before { content: "\f159"; } +.bi-badge-3d-fill::before { content: "\f15a"; } +.bi-badge-3d::before { content: "\f15b"; } +.bi-badge-4k-fill::before { content: "\f15c"; } +.bi-badge-4k::before { content: "\f15d"; } +.bi-badge-8k-fill::before { content: "\f15e"; } +.bi-badge-8k::before { content: "\f15f"; } +.bi-badge-ad-fill::before { content: "\f160"; } +.bi-badge-ad::before { content: "\f161"; } +.bi-badge-ar-fill::before { content: "\f162"; } +.bi-badge-ar::before { content: "\f163"; } +.bi-badge-cc-fill::before { content: "\f164"; } +.bi-badge-cc::before { content: "\f165"; } +.bi-badge-hd-fill::before { content: "\f166"; } +.bi-badge-hd::before { content: "\f167"; } +.bi-badge-tm-fill::before { content: "\f168"; } +.bi-badge-tm::before { content: "\f169"; } +.bi-badge-vo-fill::before { content: "\f16a"; } +.bi-badge-vo::before { content: "\f16b"; } +.bi-badge-vr-fill::before { content: "\f16c"; } +.bi-badge-vr::before { content: "\f16d"; } +.bi-badge-wc-fill::before { content: "\f16e"; } +.bi-badge-wc::before { content: "\f16f"; } +.bi-bag-check-fill::before { content: "\f170"; } +.bi-bag-check::before { content: "\f171"; } +.bi-bag-dash-fill::before { content: "\f172"; } +.bi-bag-dash::before { content: "\f173"; } +.bi-bag-fill::before { content: "\f174"; } +.bi-bag-plus-fill::before { content: "\f175"; } +.bi-bag-plus::before { content: "\f176"; } +.bi-bag-x-fill::before { content: "\f177"; } +.bi-bag-x::before { content: "\f178"; } +.bi-bag::before { content: "\f179"; } +.bi-bar-chart-fill::before { content: "\f17a"; } +.bi-bar-chart-line-fill::before { content: "\f17b"; } +.bi-bar-chart-line::before { content: "\f17c"; } +.bi-bar-chart-steps::before { content: "\f17d"; } +.bi-bar-chart::before { content: "\f17e"; } +.bi-basket-fill::before { content: "\f17f"; } +.bi-basket::before { content: "\f180"; } +.bi-basket2-fill::before { content: "\f181"; } +.bi-basket2::before { content: "\f182"; } +.bi-basket3-fill::before { content: "\f183"; } +.bi-basket3::before { content: "\f184"; } +.bi-battery-charging::before { content: "\f185"; } +.bi-battery-full::before { content: "\f186"; } +.bi-battery-half::before { content: "\f187"; } +.bi-battery::before { content: "\f188"; } +.bi-bell-fill::before { content: "\f189"; } +.bi-bell::before { content: "\f18a"; } +.bi-bezier::before { content: "\f18b"; } +.bi-bezier2::before { content: "\f18c"; } +.bi-bicycle::before { content: "\f18d"; } +.bi-binoculars-fill::before { content: "\f18e"; } +.bi-binoculars::before { content: "\f18f"; } +.bi-blockquote-left::before { content: "\f190"; } +.bi-blockquote-right::before { content: "\f191"; } +.bi-book-fill::before { content: "\f192"; } +.bi-book-half::before { content: "\f193"; } +.bi-book::before { content: "\f194"; } +.bi-bookmark-check-fill::before { content: "\f195"; } +.bi-bookmark-check::before { content: "\f196"; } +.bi-bookmark-dash-fill::before { content: "\f197"; } +.bi-bookmark-dash::before { content: "\f198"; } +.bi-bookmark-fill::before { content: "\f199"; } +.bi-bookmark-heart-fill::before { content: "\f19a"; } +.bi-bookmark-heart::before { content: "\f19b"; } +.bi-bookmark-plus-fill::before { content: "\f19c"; } +.bi-bookmark-plus::before { content: "\f19d"; } +.bi-bookmark-star-fill::before { content: "\f19e"; } +.bi-bookmark-star::before { content: "\f19f"; } +.bi-bookmark-x-fill::before { content: "\f1a0"; } +.bi-bookmark-x::before { content: "\f1a1"; } +.bi-bookmark::before { content: "\f1a2"; } +.bi-bookmarks-fill::before { content: "\f1a3"; } +.bi-bookmarks::before { content: "\f1a4"; } +.bi-bookshelf::before { content: "\f1a5"; } +.bi-bootstrap-fill::before { content: "\f1a6"; } +.bi-bootstrap-reboot::before { content: "\f1a7"; } +.bi-bootstrap::before { content: "\f1a8"; } +.bi-border-all::before { content: "\f1a9"; } +.bi-border-bottom::before { content: "\f1aa"; } +.bi-border-center::before { content: "\f1ab"; } +.bi-border-inner::before { content: "\f1ac"; } +.bi-border-left::before { content: "\f1ad"; } +.bi-border-middle::before { content: "\f1ae"; } +.bi-border-outer::before { content: "\f1af"; } +.bi-border-right::before { content: "\f1b0"; } +.bi-border-style::before { content: "\f1b1"; } +.bi-border-top::before { content: "\f1b2"; } +.bi-border-width::before { content: "\f1b3"; } +.bi-border::before { content: "\f1b4"; } +.bi-bounding-box-circles::before { content: "\f1b5"; } +.bi-bounding-box::before { content: "\f1b6"; } +.bi-box-arrow-down-left::before { content: "\f1b7"; } +.bi-box-arrow-down-right::before { content: "\f1b8"; } +.bi-box-arrow-down::before { content: "\f1b9"; } +.bi-box-arrow-in-down-left::before { content: "\f1ba"; } +.bi-box-arrow-in-down-right::before { content: "\f1bb"; } +.bi-box-arrow-in-down::before { content: "\f1bc"; } +.bi-box-arrow-in-left::before { content: "\f1bd"; } +.bi-box-arrow-in-right::before { content: "\f1be"; } +.bi-box-arrow-in-up-left::before { content: "\f1bf"; } +.bi-box-arrow-in-up-right::before { content: "\f1c0"; } +.bi-box-arrow-in-up::before { content: "\f1c1"; } +.bi-box-arrow-left::before { content: "\f1c2"; } +.bi-box-arrow-right::before { content: "\f1c3"; } +.bi-box-arrow-up-left::before { content: "\f1c4"; } +.bi-box-arrow-up-right::before { content: "\f1c5"; } +.bi-box-arrow-up::before { content: "\f1c6"; } +.bi-box-seam::before { content: "\f1c7"; } +.bi-box::before { content: "\f1c8"; } +.bi-braces::before { content: "\f1c9"; } +.bi-bricks::before { content: "\f1ca"; } +.bi-briefcase-fill::before { content: "\f1cb"; } +.bi-briefcase::before { content: "\f1cc"; } +.bi-brightness-alt-high-fill::before { content: "\f1cd"; } +.bi-brightness-alt-high::before { content: "\f1ce"; } +.bi-brightness-alt-low-fill::before { content: "\f1cf"; } +.bi-brightness-alt-low::before { content: "\f1d0"; } +.bi-brightness-high-fill::before { content: "\f1d1"; } +.bi-brightness-high::before { content: "\f1d2"; } +.bi-brightness-low-fill::before { content: "\f1d3"; } +.bi-brightness-low::before { content: "\f1d4"; } +.bi-broadcast-pin::before { content: "\f1d5"; } +.bi-broadcast::before { content: "\f1d6"; } +.bi-brush-fill::before { content: "\f1d7"; } +.bi-brush::before { content: "\f1d8"; } +.bi-bucket-fill::before { content: "\f1d9"; } +.bi-bucket::before { content: "\f1da"; } +.bi-bug-fill::before { content: "\f1db"; } +.bi-bug::before { content: "\f1dc"; } +.bi-building::before { content: "\f1dd"; } +.bi-bullseye::before { content: "\f1de"; } +.bi-calculator-fill::before { content: "\f1df"; } +.bi-calculator::before { content: "\f1e0"; } +.bi-calendar-check-fill::before { content: "\f1e1"; } +.bi-calendar-check::before { content: "\f1e2"; } +.bi-calendar-date-fill::before { content: "\f1e3"; } +.bi-calendar-date::before { content: "\f1e4"; } +.bi-calendar-day-fill::before { content: "\f1e5"; } +.bi-calendar-day::before { content: "\f1e6"; } +.bi-calendar-event-fill::before { content: "\f1e7"; } +.bi-calendar-event::before { content: "\f1e8"; } +.bi-calendar-fill::before { content: "\f1e9"; } +.bi-calendar-minus-fill::before { content: "\f1ea"; } +.bi-calendar-minus::before { content: "\f1eb"; } +.bi-calendar-month-fill::before { content: "\f1ec"; } +.bi-calendar-month::before { content: "\f1ed"; } +.bi-calendar-plus-fill::before { content: "\f1ee"; } +.bi-calendar-plus::before { content: "\f1ef"; } +.bi-calendar-range-fill::before { content: "\f1f0"; } +.bi-calendar-range::before { content: "\f1f1"; } +.bi-calendar-week-fill::before { content: "\f1f2"; } +.bi-calendar-week::before { content: "\f1f3"; } +.bi-calendar-x-fill::before { content: "\f1f4"; } +.bi-calendar-x::before { content: "\f1f5"; } +.bi-calendar::before { content: "\f1f6"; } +.bi-calendar2-check-fill::before { content: "\f1f7"; } +.bi-calendar2-check::before { content: "\f1f8"; } +.bi-calendar2-date-fill::before { content: "\f1f9"; } +.bi-calendar2-date::before { content: "\f1fa"; } +.bi-calendar2-day-fill::before { content: "\f1fb"; } +.bi-calendar2-day::before { content: "\f1fc"; } +.bi-calendar2-event-fill::before { content: "\f1fd"; } +.bi-calendar2-event::before { content: "\f1fe"; } +.bi-calendar2-fill::before { content: "\f1ff"; } +.bi-calendar2-minus-fill::before { content: "\f200"; } +.bi-calendar2-minus::before { content: "\f201"; } +.bi-calendar2-month-fill::before { content: "\f202"; } +.bi-calendar2-month::before { content: "\f203"; } +.bi-calendar2-plus-fill::before { content: "\f204"; } +.bi-calendar2-plus::before { content: "\f205"; } +.bi-calendar2-range-fill::before { content: "\f206"; } +.bi-calendar2-range::before { content: "\f207"; } +.bi-calendar2-week-fill::before { content: "\f208"; } +.bi-calendar2-week::before { content: "\f209"; } +.bi-calendar2-x-fill::before { content: "\f20a"; } +.bi-calendar2-x::before { content: "\f20b"; } +.bi-calendar2::before { content: "\f20c"; } +.bi-calendar3-event-fill::before { content: "\f20d"; } +.bi-calendar3-event::before { content: "\f20e"; } +.bi-calendar3-fill::before { content: "\f20f"; } +.bi-calendar3-range-fill::before { content: "\f210"; } +.bi-calendar3-range::before { content: "\f211"; } +.bi-calendar3-week-fill::before { content: "\f212"; } +.bi-calendar3-week::before { content: "\f213"; } +.bi-calendar3::before { content: "\f214"; } +.bi-calendar4-event::before { content: "\f215"; } +.bi-calendar4-range::before { content: "\f216"; } +.bi-calendar4-week::before { content: "\f217"; } +.bi-calendar4::before { content: "\f218"; } +.bi-camera-fill::before { content: "\f219"; } +.bi-camera-reels-fill::before { content: "\f21a"; } +.bi-camera-reels::before { content: "\f21b"; } +.bi-camera-video-fill::before { content: "\f21c"; } +.bi-camera-video-off-fill::before { content: "\f21d"; } +.bi-camera-video-off::before { content: "\f21e"; } +.bi-camera-video::before { content: "\f21f"; } +.bi-camera::before { content: "\f220"; } +.bi-camera2::before { content: "\f221"; } +.bi-capslock-fill::before { content: "\f222"; } +.bi-capslock::before { content: "\f223"; } +.bi-card-checklist::before { content: "\f224"; } +.bi-card-heading::before { content: "\f225"; } +.bi-card-image::before { content: "\f226"; } +.bi-card-list::before { content: "\f227"; } +.bi-card-text::before { content: "\f228"; } +.bi-caret-down-fill::before { content: "\f229"; } +.bi-caret-down-square-fill::before { content: "\f22a"; } +.bi-caret-down-square::before { content: "\f22b"; } +.bi-caret-down::before { content: "\f22c"; } +.bi-caret-left-fill::before { content: "\f22d"; } +.bi-caret-left-square-fill::before { content: "\f22e"; } +.bi-caret-left-square::before { content: "\f22f"; } +.bi-caret-left::before { content: "\f230"; } +.bi-caret-right-fill::before { content: "\f231"; } +.bi-caret-right-square-fill::before { content: "\f232"; } +.bi-caret-right-square::before { content: "\f233"; } +.bi-caret-right::before { content: "\f234"; } +.bi-caret-up-fill::before { content: "\f235"; } +.bi-caret-up-square-fill::before { content: "\f236"; } +.bi-caret-up-square::before { content: "\f237"; } +.bi-caret-up::before { content: "\f238"; } +.bi-cart-check-fill::before { content: "\f239"; } +.bi-cart-check::before { content: "\f23a"; } +.bi-cart-dash-fill::before { content: "\f23b"; } +.bi-cart-dash::before { content: "\f23c"; } +.bi-cart-fill::before { content: "\f23d"; } +.bi-cart-plus-fill::before { content: "\f23e"; } +.bi-cart-plus::before { content: "\f23f"; } +.bi-cart-x-fill::before { content: "\f240"; } +.bi-cart-x::before { content: "\f241"; } +.bi-cart::before { content: "\f242"; } +.bi-cart2::before { content: "\f243"; } +.bi-cart3::before { content: "\f244"; } +.bi-cart4::before { content: "\f245"; } +.bi-cash-stack::before { content: "\f246"; } +.bi-cash::before { content: "\f247"; } +.bi-cast::before { content: "\f248"; } +.bi-chat-dots-fill::before { content: "\f249"; } +.bi-chat-dots::before { content: "\f24a"; } +.bi-chat-fill::before { content: "\f24b"; } +.bi-chat-left-dots-fill::before { content: "\f24c"; } +.bi-chat-left-dots::before { content: "\f24d"; } +.bi-chat-left-fill::before { content: "\f24e"; } +.bi-chat-left-quote-fill::before { content: "\f24f"; } +.bi-chat-left-quote::before { content: "\f250"; } +.bi-chat-left-text-fill::before { content: "\f251"; } +.bi-chat-left-text::before { content: "\f252"; } +.bi-chat-left::before { content: "\f253"; } +.bi-chat-quote-fill::before { content: "\f254"; } +.bi-chat-quote::before { content: "\f255"; } +.bi-chat-right-dots-fill::before { content: "\f256"; } +.bi-chat-right-dots::before { content: "\f257"; } +.bi-chat-right-fill::before { content: "\f258"; } +.bi-chat-right-quote-fill::before { content: "\f259"; } +.bi-chat-right-quote::before { content: "\f25a"; } +.bi-chat-right-text-fill::before { content: "\f25b"; } +.bi-chat-right-text::before { content: "\f25c"; } +.bi-chat-right::before { content: "\f25d"; } +.bi-chat-square-dots-fill::before { content: "\f25e"; } +.bi-chat-square-dots::before { content: "\f25f"; } +.bi-chat-square-fill::before { content: "\f260"; } +.bi-chat-square-quote-fill::before { content: "\f261"; } +.bi-chat-square-quote::before { content: "\f262"; } +.bi-chat-square-text-fill::before { content: "\f263"; } +.bi-chat-square-text::before { content: "\f264"; } +.bi-chat-square::before { content: "\f265"; } +.bi-chat-text-fill::before { content: "\f266"; } +.bi-chat-text::before { content: "\f267"; } +.bi-chat::before { content: "\f268"; } +.bi-check-all::before { content: "\f269"; } +.bi-check-circle-fill::before { content: "\f26a"; } +.bi-check-circle::before { content: "\f26b"; } +.bi-check-square-fill::before { content: "\f26c"; } +.bi-check-square::before { content: "\f26d"; } +.bi-check::before { content: "\f26e"; } +.bi-check2-all::before { content: "\f26f"; } +.bi-check2-circle::before { content: "\f270"; } +.bi-check2-square::before { content: "\f271"; } +.bi-check2::before { content: "\f272"; } +.bi-chevron-bar-contract::before { content: "\f273"; } +.bi-chevron-bar-down::before { content: "\f274"; } +.bi-chevron-bar-expand::before { content: "\f275"; } +.bi-chevron-bar-left::before { content: "\f276"; } +.bi-chevron-bar-right::before { content: "\f277"; } +.bi-chevron-bar-up::before { content: "\f278"; } +.bi-chevron-compact-down::before { content: "\f279"; } +.bi-chevron-compact-left::before { content: "\f27a"; } +.bi-chevron-compact-right::before { content: "\f27b"; } +.bi-chevron-compact-up::before { content: "\f27c"; } +.bi-chevron-contract::before { content: "\f27d"; } +.bi-chevron-double-down::before { content: "\f27e"; } +.bi-chevron-double-left::before { content: "\f27f"; } +.bi-chevron-double-right::before { content: "\f280"; } +.bi-chevron-double-up::before { content: "\f281"; } +.bi-chevron-down::before { content: "\f282"; } +.bi-chevron-expand::before { content: "\f283"; } +.bi-chevron-left::before { content: "\f284"; } +.bi-chevron-right::before { content: "\f285"; } +.bi-chevron-up::before { content: "\f286"; } +.bi-circle-fill::before { content: "\f287"; } +.bi-circle-half::before { content: "\f288"; } +.bi-circle-square::before { content: "\f289"; } +.bi-circle::before { content: "\f28a"; } +.bi-clipboard-check::before { content: "\f28b"; } +.bi-clipboard-data::before { content: "\f28c"; } +.bi-clipboard-minus::before { content: "\f28d"; } +.bi-clipboard-plus::before { content: "\f28e"; } +.bi-clipboard-x::before { content: "\f28f"; } +.bi-clipboard::before { content: "\f290"; } +.bi-clock-fill::before { content: "\f291"; } +.bi-clock-history::before { content: "\f292"; } +.bi-clock::before { content: "\f293"; } +.bi-cloud-arrow-down-fill::before { content: "\f294"; } +.bi-cloud-arrow-down::before { content: "\f295"; } +.bi-cloud-arrow-up-fill::before { content: "\f296"; } +.bi-cloud-arrow-up::before { content: "\f297"; } +.bi-cloud-check-fill::before { content: "\f298"; } +.bi-cloud-check::before { content: "\f299"; } +.bi-cloud-download-fill::before { content: "\f29a"; } +.bi-cloud-download::before { content: "\f29b"; } +.bi-cloud-drizzle-fill::before { content: "\f29c"; } +.bi-cloud-drizzle::before { content: "\f29d"; } +.bi-cloud-fill::before { content: "\f29e"; } +.bi-cloud-fog-fill::before { content: "\f29f"; } +.bi-cloud-fog::before { content: "\f2a0"; } +.bi-cloud-fog2-fill::before { content: "\f2a1"; } +.bi-cloud-fog2::before { content: "\f2a2"; } +.bi-cloud-hail-fill::before { content: "\f2a3"; } +.bi-cloud-hail::before { content: "\f2a4"; } +.bi-cloud-haze-1::before { content: "\f2a5"; } +.bi-cloud-haze-fill::before { content: "\f2a6"; } +.bi-cloud-haze::before { content: "\f2a7"; } +.bi-cloud-haze2-fill::before { content: "\f2a8"; } +.bi-cloud-lightning-fill::before { content: "\f2a9"; } +.bi-cloud-lightning-rain-fill::before { content: "\f2aa"; } +.bi-cloud-lightning-rain::before { content: "\f2ab"; } +.bi-cloud-lightning::before { content: "\f2ac"; } +.bi-cloud-minus-fill::before { content: "\f2ad"; } +.bi-cloud-minus::before { content: "\f2ae"; } +.bi-cloud-moon-fill::before { content: "\f2af"; } +.bi-cloud-moon::before { content: "\f2b0"; } +.bi-cloud-plus-fill::before { content: "\f2b1"; } +.bi-cloud-plus::before { content: "\f2b2"; } +.bi-cloud-rain-fill::before { content: "\f2b3"; } +.bi-cloud-rain-heavy-fill::before { content: "\f2b4"; } +.bi-cloud-rain-heavy::before { content: "\f2b5"; } +.bi-cloud-rain::before { content: "\f2b6"; } +.bi-cloud-slash-fill::before { content: "\f2b7"; } +.bi-cloud-slash::before { content: "\f2b8"; } +.bi-cloud-sleet-fill::before { content: "\f2b9"; } +.bi-cloud-sleet::before { content: "\f2ba"; } +.bi-cloud-snow-fill::before { content: "\f2bb"; } +.bi-cloud-snow::before { content: "\f2bc"; } +.bi-cloud-sun-fill::before { content: "\f2bd"; } +.bi-cloud-sun::before { content: "\f2be"; } +.bi-cloud-upload-fill::before { content: "\f2bf"; } +.bi-cloud-upload::before { content: "\f2c0"; } +.bi-cloud::before { content: "\f2c1"; } +.bi-clouds-fill::before { content: "\f2c2"; } +.bi-clouds::before { content: "\f2c3"; } +.bi-cloudy-fill::before { content: "\f2c4"; } +.bi-cloudy::before { content: "\f2c5"; } +.bi-code-slash::before { content: "\f2c6"; } +.bi-code-square::before { content: "\f2c7"; } +.bi-code::before { content: "\f2c8"; } +.bi-collection-fill::before { content: "\f2c9"; } +.bi-collection-play-fill::before { content: "\f2ca"; } +.bi-collection-play::before { content: "\f2cb"; } +.bi-collection::before { content: "\f2cc"; } +.bi-columns-gap::before { content: "\f2cd"; } +.bi-columns::before { content: "\f2ce"; } +.bi-command::before { content: "\f2cf"; } +.bi-compass-fill::before { content: "\f2d0"; } +.bi-compass::before { content: "\f2d1"; } +.bi-cone-striped::before { content: "\f2d2"; } +.bi-cone::before { content: "\f2d3"; } +.bi-controller::before { content: "\f2d4"; } +.bi-cpu-fill::before { content: "\f2d5"; } +.bi-cpu::before { content: "\f2d6"; } +.bi-credit-card-2-back-fill::before { content: "\f2d7"; } +.bi-credit-card-2-back::before { content: "\f2d8"; } +.bi-credit-card-2-front-fill::before { content: "\f2d9"; } +.bi-credit-card-2-front::before { content: "\f2da"; } +.bi-credit-card-fill::before { content: "\f2db"; } +.bi-credit-card::before { content: "\f2dc"; } +.bi-crop::before { content: "\f2dd"; } +.bi-cup-fill::before { content: "\f2de"; } +.bi-cup-straw::before { content: "\f2df"; } +.bi-cup::before { content: "\f2e0"; } +.bi-cursor-fill::before { content: "\f2e1"; } +.bi-cursor-text::before { content: "\f2e2"; } +.bi-cursor::before { content: "\f2e3"; } +.bi-dash-circle-dotted::before { content: "\f2e4"; } +.bi-dash-circle-fill::before { content: "\f2e5"; } +.bi-dash-circle::before { content: "\f2e6"; } +.bi-dash-square-dotted::before { content: "\f2e7"; } +.bi-dash-square-fill::before { content: "\f2e8"; } +.bi-dash-square::before { content: "\f2e9"; } +.bi-dash::before { content: "\f2ea"; } +.bi-diagram-2-fill::before { content: "\f2eb"; } +.bi-diagram-2::before { content: "\f2ec"; } +.bi-diagram-3-fill::before { content: "\f2ed"; } +.bi-diagram-3::before { content: "\f2ee"; } +.bi-diamond-fill::before { content: "\f2ef"; } +.bi-diamond-half::before { content: "\f2f0"; } +.bi-diamond::before { content: "\f2f1"; } +.bi-dice-1-fill::before { content: "\f2f2"; } +.bi-dice-1::before { content: "\f2f3"; } +.bi-dice-2-fill::before { content: "\f2f4"; } +.bi-dice-2::before { content: "\f2f5"; } +.bi-dice-3-fill::before { content: "\f2f6"; } +.bi-dice-3::before { content: "\f2f7"; } +.bi-dice-4-fill::before { content: "\f2f8"; } +.bi-dice-4::before { content: "\f2f9"; } +.bi-dice-5-fill::before { content: "\f2fa"; } +.bi-dice-5::before { content: "\f2fb"; } +.bi-dice-6-fill::before { content: "\f2fc"; } +.bi-dice-6::before { content: "\f2fd"; } +.bi-disc-fill::before { content: "\f2fe"; } +.bi-disc::before { content: "\f2ff"; } +.bi-discord::before { content: "\f300"; } +.bi-display-fill::before { content: "\f301"; } +.bi-display::before { content: "\f302"; } +.bi-distribute-horizontal::before { content: "\f303"; } +.bi-distribute-vertical::before { content: "\f304"; } +.bi-door-closed-fill::before { content: "\f305"; } +.bi-door-closed::before { content: "\f306"; } +.bi-door-open-fill::before { content: "\f307"; } +.bi-door-open::before { content: "\f308"; } +.bi-dot::before { content: "\f309"; } +.bi-download::before { content: "\f30a"; } +.bi-droplet-fill::before { content: "\f30b"; } +.bi-droplet-half::before { content: "\f30c"; } +.bi-droplet::before { content: "\f30d"; } +.bi-earbuds::before { content: "\f30e"; } +.bi-easel-fill::before { content: "\f30f"; } +.bi-easel::before { content: "\f310"; } +.bi-egg-fill::before { content: "\f311"; } +.bi-egg-fried::before { content: "\f312"; } +.bi-egg::before { content: "\f313"; } +.bi-eject-fill::before { content: "\f314"; } +.bi-eject::before { content: "\f315"; } +.bi-emoji-angry-fill::before { content: "\f316"; } +.bi-emoji-angry::before { content: "\f317"; } +.bi-emoji-dizzy-fill::before { content: "\f318"; } +.bi-emoji-dizzy::before { content: "\f319"; } +.bi-emoji-expressionless-fill::before { content: "\f31a"; } +.bi-emoji-expressionless::before { content: "\f31b"; } +.bi-emoji-frown-fill::before { content: "\f31c"; } +.bi-emoji-frown::before { content: "\f31d"; } +.bi-emoji-heart-eyes-fill::before { content: "\f31e"; } +.bi-emoji-heart-eyes::before { content: "\f31f"; } +.bi-emoji-laughing-fill::before { content: "\f320"; } +.bi-emoji-laughing::before { content: "\f321"; } +.bi-emoji-neutral-fill::before { content: "\f322"; } +.bi-emoji-neutral::before { content: "\f323"; } +.bi-emoji-smile-fill::before { content: "\f324"; } +.bi-emoji-smile-upside-down-fill::before { content: "\f325"; } +.bi-emoji-smile-upside-down::before { content: "\f326"; } +.bi-emoji-smile::before { content: "\f327"; } +.bi-emoji-sunglasses-fill::before { content: "\f328"; } +.bi-emoji-sunglasses::before { content: "\f329"; } +.bi-emoji-wink-fill::before { content: "\f32a"; } +.bi-emoji-wink::before { content: "\f32b"; } +.bi-envelope-fill::before { content: "\f32c"; } +.bi-envelope-open-fill::before { content: "\f32d"; } +.bi-envelope-open::before { content: "\f32e"; } +.bi-envelope::before { content: "\f32f"; } +.bi-eraser-fill::before { content: "\f330"; } +.bi-eraser::before { content: "\f331"; } +.bi-exclamation-circle-fill::before { content: "\f332"; } +.bi-exclamation-circle::before { content: "\f333"; } +.bi-exclamation-diamond-fill::before { content: "\f334"; } +.bi-exclamation-diamond::before { content: "\f335"; } +.bi-exclamation-octagon-fill::before { content: "\f336"; } +.bi-exclamation-octagon::before { content: "\f337"; } +.bi-exclamation-square-fill::before { content: "\f338"; } +.bi-exclamation-square::before { content: "\f339"; } +.bi-exclamation-triangle-fill::before { content: "\f33a"; } +.bi-exclamation-triangle::before { content: "\f33b"; } +.bi-exclamation::before { content: "\f33c"; } +.bi-exclude::before { content: "\f33d"; } +.bi-eye-fill::before { content: "\f33e"; } +.bi-eye-slash-fill::before { content: "\f33f"; } +.bi-eye-slash::before { content: "\f340"; } +.bi-eye::before { content: "\f341"; } +.bi-eyedropper::before { content: "\f342"; } +.bi-eyeglasses::before { content: "\f343"; } +.bi-facebook::before { content: "\f344"; } +.bi-file-arrow-down-fill::before { content: "\f345"; } +.bi-file-arrow-down::before { content: "\f346"; } +.bi-file-arrow-up-fill::before { content: "\f347"; } +.bi-file-arrow-up::before { content: "\f348"; } +.bi-file-bar-graph-fill::before { content: "\f349"; } +.bi-file-bar-graph::before { content: "\f34a"; } +.bi-file-binary-fill::before { content: "\f34b"; } +.bi-file-binary::before { content: "\f34c"; } +.bi-file-break-fill::before { content: "\f34d"; } +.bi-file-break::before { content: "\f34e"; } +.bi-file-check-fill::before { content: "\f34f"; } +.bi-file-check::before { content: "\f350"; } +.bi-file-code-fill::before { content: "\f351"; } +.bi-file-code::before { content: "\f352"; } +.bi-file-diff-fill::before { content: "\f353"; } +.bi-file-diff::before { content: "\f354"; } +.bi-file-earmark-arrow-down-fill::before { content: "\f355"; } +.bi-file-earmark-arrow-down::before { content: "\f356"; } +.bi-file-earmark-arrow-up-fill::before { content: "\f357"; } +.bi-file-earmark-arrow-up::before { content: "\f358"; } +.bi-file-earmark-bar-graph-fill::before { content: "\f359"; } +.bi-file-earmark-bar-graph::before { content: "\f35a"; } +.bi-file-earmark-binary-fill::before { content: "\f35b"; } +.bi-file-earmark-binary::before { content: "\f35c"; } +.bi-file-earmark-break-fill::before { content: "\f35d"; } +.bi-file-earmark-break::before { content: "\f35e"; } +.bi-file-earmark-check-fill::before { content: "\f35f"; } +.bi-file-earmark-check::before { content: "\f360"; } +.bi-file-earmark-code-fill::before { content: "\f361"; } +.bi-file-earmark-code::before { content: "\f362"; } +.bi-file-earmark-diff-fill::before { content: "\f363"; } +.bi-file-earmark-diff::before { content: "\f364"; } +.bi-file-earmark-easel-fill::before { content: "\f365"; } +.bi-file-earmark-easel::before { content: "\f366"; } +.bi-file-earmark-excel-fill::before { content: "\f367"; } +.bi-file-earmark-excel::before { content: "\f368"; } +.bi-file-earmark-fill::before { content: "\f369"; } +.bi-file-earmark-font-fill::before { content: "\f36a"; } +.bi-file-earmark-font::before { content: "\f36b"; } +.bi-file-earmark-image-fill::before { content: "\f36c"; } +.bi-file-earmark-image::before { content: "\f36d"; } +.bi-file-earmark-lock-fill::before { content: "\f36e"; } +.bi-file-earmark-lock::before { content: "\f36f"; } +.bi-file-earmark-lock2-fill::before { content: "\f370"; } +.bi-file-earmark-lock2::before { content: "\f371"; } +.bi-file-earmark-medical-fill::before { content: "\f372"; } +.bi-file-earmark-medical::before { content: "\f373"; } +.bi-file-earmark-minus-fill::before { content: "\f374"; } +.bi-file-earmark-minus::before { content: "\f375"; } +.bi-file-earmark-music-fill::before { content: "\f376"; } +.bi-file-earmark-music::before { content: "\f377"; } +.bi-file-earmark-person-fill::before { content: "\f378"; } +.bi-file-earmark-person::before { content: "\f379"; } +.bi-file-earmark-play-fill::before { content: "\f37a"; } +.bi-file-earmark-play::before { content: "\f37b"; } +.bi-file-earmark-plus-fill::before { content: "\f37c"; } +.bi-file-earmark-plus::before { content: "\f37d"; } +.bi-file-earmark-post-fill::before { content: "\f37e"; } +.bi-file-earmark-post::before { content: "\f37f"; } +.bi-file-earmark-ppt-fill::before { content: "\f380"; } +.bi-file-earmark-ppt::before { content: "\f381"; } +.bi-file-earmark-richtext-fill::before { content: "\f382"; } +.bi-file-earmark-richtext::before { content: "\f383"; } +.bi-file-earmark-ruled-fill::before { content: "\f384"; } +.bi-file-earmark-ruled::before { content: "\f385"; } +.bi-file-earmark-slides-fill::before { content: "\f386"; } +.bi-file-earmark-slides::before { content: "\f387"; } +.bi-file-earmark-spreadsheet-fill::before { content: "\f388"; } +.bi-file-earmark-spreadsheet::before { content: "\f389"; } +.bi-file-earmark-text-fill::before { content: "\f38a"; } +.bi-file-earmark-text::before { content: "\f38b"; } +.bi-file-earmark-word-fill::before { content: "\f38c"; } +.bi-file-earmark-word::before { content: "\f38d"; } +.bi-file-earmark-x-fill::before { content: "\f38e"; } +.bi-file-earmark-x::before { content: "\f38f"; } +.bi-file-earmark-zip-fill::before { content: "\f390"; } +.bi-file-earmark-zip::before { content: "\f391"; } +.bi-file-earmark::before { content: "\f392"; } +.bi-file-easel-fill::before { content: "\f393"; } +.bi-file-easel::before { content: "\f394"; } +.bi-file-excel-fill::before { content: "\f395"; } +.bi-file-excel::before { content: "\f396"; } +.bi-file-fill::before { content: "\f397"; } +.bi-file-font-fill::before { content: "\f398"; } +.bi-file-font::before { content: "\f399"; } +.bi-file-image-fill::before { content: "\f39a"; } +.bi-file-image::before { content: "\f39b"; } +.bi-file-lock-fill::before { content: "\f39c"; } +.bi-file-lock::before { content: "\f39d"; } +.bi-file-lock2-fill::before { content: "\f39e"; } +.bi-file-lock2::before { content: "\f39f"; } +.bi-file-medical-fill::before { content: "\f3a0"; } +.bi-file-medical::before { content: "\f3a1"; } +.bi-file-minus-fill::before { content: "\f3a2"; } +.bi-file-minus::before { content: "\f3a3"; } +.bi-file-music-fill::before { content: "\f3a4"; } +.bi-file-music::before { content: "\f3a5"; } +.bi-file-person-fill::before { content: "\f3a6"; } +.bi-file-person::before { content: "\f3a7"; } +.bi-file-play-fill::before { content: "\f3a8"; } +.bi-file-play::before { content: "\f3a9"; } +.bi-file-plus-fill::before { content: "\f3aa"; } +.bi-file-plus::before { content: "\f3ab"; } +.bi-file-post-fill::before { content: "\f3ac"; } +.bi-file-post::before { content: "\f3ad"; } +.bi-file-ppt-fill::before { content: "\f3ae"; } +.bi-file-ppt::before { content: "\f3af"; } +.bi-file-richtext-fill::before { content: "\f3b0"; } +.bi-file-richtext::before { content: "\f3b1"; } +.bi-file-ruled-fill::before { content: "\f3b2"; } +.bi-file-ruled::before { content: "\f3b3"; } +.bi-file-slides-fill::before { content: "\f3b4"; } +.bi-file-slides::before { content: "\f3b5"; } +.bi-file-spreadsheet-fill::before { content: "\f3b6"; } +.bi-file-spreadsheet::before { content: "\f3b7"; } +.bi-file-text-fill::before { content: "\f3b8"; } +.bi-file-text::before { content: "\f3b9"; } +.bi-file-word-fill::before { content: "\f3ba"; } +.bi-file-word::before { content: "\f3bb"; } +.bi-file-x-fill::before { content: "\f3bc"; } +.bi-file-x::before { content: "\f3bd"; } +.bi-file-zip-fill::before { content: "\f3be"; } +.bi-file-zip::before { content: "\f3bf"; } +.bi-file::before { content: "\f3c0"; } +.bi-files-alt::before { content: "\f3c1"; } +.bi-files::before { content: "\f3c2"; } +.bi-film::before { content: "\f3c3"; } +.bi-filter-circle-fill::before { content: "\f3c4"; } +.bi-filter-circle::before { content: "\f3c5"; } +.bi-filter-left::before { content: "\f3c6"; } +.bi-filter-right::before { content: "\f3c7"; } +.bi-filter-square-fill::before { content: "\f3c8"; } +.bi-filter-square::before { content: "\f3c9"; } +.bi-filter::before { content: "\f3ca"; } +.bi-flag-fill::before { content: "\f3cb"; } +.bi-flag::before { content: "\f3cc"; } +.bi-flower1::before { content: "\f3cd"; } +.bi-flower2::before { content: "\f3ce"; } +.bi-flower3::before { content: "\f3cf"; } +.bi-folder-check::before { content: "\f3d0"; } +.bi-folder-fill::before { content: "\f3d1"; } +.bi-folder-minus::before { content: "\f3d2"; } +.bi-folder-plus::before { content: "\f3d3"; } +.bi-folder-symlink-fill::before { content: "\f3d4"; } +.bi-folder-symlink::before { content: "\f3d5"; } +.bi-folder-x::before { content: "\f3d6"; } +.bi-folder::before { content: "\f3d7"; } +.bi-folder2-open::before { content: "\f3d8"; } +.bi-folder2::before { content: "\f3d9"; } +.bi-fonts::before { content: "\f3da"; } +.bi-forward-fill::before { content: "\f3db"; } +.bi-forward::before { content: "\f3dc"; } +.bi-front::before { content: "\f3dd"; } +.bi-fullscreen-exit::before { content: "\f3de"; } +.bi-fullscreen::before { content: "\f3df"; } +.bi-funnel-fill::before { content: "\f3e0"; } +.bi-funnel::before { content: "\f3e1"; } +.bi-gear-fill::before { content: "\f3e2"; } +.bi-gear-wide-connected::before { content: "\f3e3"; } +.bi-gear-wide::before { content: "\f3e4"; } +.bi-gear::before { content: "\f3e5"; } +.bi-gem::before { content: "\f3e6"; } +.bi-geo-alt-fill::before { content: "\f3e7"; } +.bi-geo-alt::before { content: "\f3e8"; } +.bi-geo-fill::before { content: "\f3e9"; } +.bi-geo::before { content: "\f3ea"; } +.bi-gift-fill::before { content: "\f3eb"; } +.bi-gift::before { content: "\f3ec"; } +.bi-github::before { content: "\f3ed"; } +.bi-globe::before { content: "\f3ee"; } +.bi-globe2::before { content: "\f3ef"; } +.bi-google::before { content: "\f3f0"; } +.bi-graph-down::before { content: "\f3f1"; } +.bi-graph-up::before { content: "\f3f2"; } +.bi-grid-1x2-fill::before { content: "\f3f3"; } +.bi-grid-1x2::before { content: "\f3f4"; } +.bi-grid-3x2-gap-fill::before { content: "\f3f5"; } +.bi-grid-3x2-gap::before { content: "\f3f6"; } +.bi-grid-3x2::before { content: "\f3f7"; } +.bi-grid-3x3-gap-fill::before { content: "\f3f8"; } +.bi-grid-3x3-gap::before { content: "\f3f9"; } +.bi-grid-3x3::before { content: "\f3fa"; } +.bi-grid-fill::before { content: "\f3fb"; } +.bi-grid::before { content: "\f3fc"; } +.bi-grip-horizontal::before { content: "\f3fd"; } +.bi-grip-vertical::before { content: "\f3fe"; } +.bi-hammer::before { content: "\f3ff"; } +.bi-hand-index-fill::before { content: "\f400"; } +.bi-hand-index-thumb-fill::before { content: "\f401"; } +.bi-hand-index-thumb::before { content: "\f402"; } +.bi-hand-index::before { content: "\f403"; } +.bi-hand-thumbs-down-fill::before { content: "\f404"; } +.bi-hand-thumbs-down::before { content: "\f405"; } +.bi-hand-thumbs-up-fill::before { content: "\f406"; } +.bi-hand-thumbs-up::before { content: "\f407"; } +.bi-handbag-fill::before { content: "\f408"; } +.bi-handbag::before { content: "\f409"; } +.bi-hash::before { content: "\f40a"; } +.bi-hdd-fill::before { content: "\f40b"; } +.bi-hdd-network-fill::before { content: "\f40c"; } +.bi-hdd-network::before { content: "\f40d"; } +.bi-hdd-rack-fill::before { content: "\f40e"; } +.bi-hdd-rack::before { content: "\f40f"; } +.bi-hdd-stack-fill::before { content: "\f410"; } +.bi-hdd-stack::before { content: "\f411"; } +.bi-hdd::before { content: "\f412"; } +.bi-headphones::before { content: "\f413"; } +.bi-headset::before { content: "\f414"; } +.bi-heart-fill::before { content: "\f415"; } +.bi-heart-half::before { content: "\f416"; } +.bi-heart::before { content: "\f417"; } +.bi-heptagon-fill::before { content: "\f418"; } +.bi-heptagon-half::before { content: "\f419"; } +.bi-heptagon::before { content: "\f41a"; } +.bi-hexagon-fill::before { content: "\f41b"; } +.bi-hexagon-half::before { content: "\f41c"; } +.bi-hexagon::before { content: "\f41d"; } +.bi-hourglass-bottom::before { content: "\f41e"; } +.bi-hourglass-split::before { content: "\f41f"; } +.bi-hourglass-top::before { content: "\f420"; } +.bi-hourglass::before { content: "\f421"; } +.bi-house-door-fill::before { content: "\f422"; } +.bi-house-door::before { content: "\f423"; } +.bi-house-fill::before { content: "\f424"; } +.bi-house::before { content: "\f425"; } +.bi-hr::before { content: "\f426"; } +.bi-hurricane::before { content: "\f427"; } +.bi-image-alt::before { content: "\f428"; } +.bi-image-fill::before { content: "\f429"; } +.bi-image::before { content: "\f42a"; } +.bi-images::before { content: "\f42b"; } +.bi-inbox-fill::before { content: "\f42c"; } +.bi-inbox::before { content: "\f42d"; } +.bi-inboxes-fill::before { content: "\f42e"; } +.bi-inboxes::before { content: "\f42f"; } +.bi-info-circle-fill::before { content: "\f430"; } +.bi-info-circle::before { content: "\f431"; } +.bi-info-square-fill::before { content: "\f432"; } +.bi-info-square::before { content: "\f433"; } +.bi-info::before { content: "\f434"; } +.bi-input-cursor-text::before { content: "\f435"; } +.bi-input-cursor::before { content: "\f436"; } +.bi-instagram::before { content: "\f437"; } +.bi-intersect::before { content: "\f438"; } +.bi-journal-album::before { content: "\f439"; } +.bi-journal-arrow-down::before { content: "\f43a"; } +.bi-journal-arrow-up::before { content: "\f43b"; } +.bi-journal-bookmark-fill::before { content: "\f43c"; } +.bi-journal-bookmark::before { content: "\f43d"; } +.bi-journal-check::before { content: "\f43e"; } +.bi-journal-code::before { content: "\f43f"; } +.bi-journal-medical::before { content: "\f440"; } +.bi-journal-minus::before { content: "\f441"; } +.bi-journal-plus::before { content: "\f442"; } +.bi-journal-richtext::before { content: "\f443"; } +.bi-journal-text::before { content: "\f444"; } +.bi-journal-x::before { content: "\f445"; } +.bi-journal::before { content: "\f446"; } +.bi-journals::before { content: "\f447"; } +.bi-joystick::before { content: "\f448"; } +.bi-justify-left::before { content: "\f449"; } +.bi-justify-right::before { content: "\f44a"; } +.bi-justify::before { content: "\f44b"; } +.bi-kanban-fill::before { content: "\f44c"; } +.bi-kanban::before { content: "\f44d"; } +.bi-key-fill::before { content: "\f44e"; } +.bi-key::before { content: "\f44f"; } +.bi-keyboard-fill::before { content: "\f450"; } +.bi-keyboard::before { content: "\f451"; } +.bi-ladder::before { content: "\f452"; } +.bi-lamp-fill::before { content: "\f453"; } +.bi-lamp::before { content: "\f454"; } +.bi-laptop-fill::before { content: "\f455"; } +.bi-laptop::before { content: "\f456"; } +.bi-layer-backward::before { content: "\f457"; } +.bi-layer-forward::before { content: "\f458"; } +.bi-layers-fill::before { content: "\f459"; } +.bi-layers-half::before { content: "\f45a"; } +.bi-layers::before { content: "\f45b"; } +.bi-layout-sidebar-inset-reverse::before { content: "\f45c"; } +.bi-layout-sidebar-inset::before { content: "\f45d"; } +.bi-layout-sidebar-reverse::before { content: "\f45e"; } +.bi-layout-sidebar::before { content: "\f45f"; } +.bi-layout-split::before { content: "\f460"; } +.bi-layout-text-sidebar-reverse::before { content: "\f461"; } +.bi-layout-text-sidebar::before { content: "\f462"; } +.bi-layout-text-window-reverse::before { content: "\f463"; } +.bi-layout-text-window::before { content: "\f464"; } +.bi-layout-three-columns::before { content: "\f465"; } +.bi-layout-wtf::before { content: "\f466"; } +.bi-life-preserver::before { content: "\f467"; } +.bi-lightbulb-fill::before { content: "\f468"; } +.bi-lightbulb-off-fill::before { content: "\f469"; } +.bi-lightbulb-off::before { content: "\f46a"; } +.bi-lightbulb::before { content: "\f46b"; } +.bi-lightning-charge-fill::before { content: "\f46c"; } +.bi-lightning-charge::before { content: "\f46d"; } +.bi-lightning-fill::before { content: "\f46e"; } +.bi-lightning::before { content: "\f46f"; } +.bi-link-45deg::before { content: "\f470"; } +.bi-link::before { content: "\f471"; } +.bi-linkedin::before { content: "\f472"; } +.bi-list-check::before { content: "\f473"; } +.bi-list-nested::before { content: "\f474"; } +.bi-list-ol::before { content: "\f475"; } +.bi-list-stars::before { content: "\f476"; } +.bi-list-task::before { content: "\f477"; } +.bi-list-ul::before { content: "\f478"; } +.bi-list::before { content: "\f479"; } +.bi-lock-fill::before { content: "\f47a"; } +.bi-lock::before { content: "\f47b"; } +.bi-mailbox::before { content: "\f47c"; } +.bi-mailbox2::before { content: "\f47d"; } +.bi-map-fill::before { content: "\f47e"; } +.bi-map::before { content: "\f47f"; } +.bi-markdown-fill::before { content: "\f480"; } +.bi-markdown::before { content: "\f481"; } +.bi-mask::before { content: "\f482"; } +.bi-megaphone-fill::before { content: "\f483"; } +.bi-megaphone::before { content: "\f484"; } +.bi-menu-app-fill::before { content: "\f485"; } +.bi-menu-app::before { content: "\f486"; } +.bi-menu-button-fill::before { content: "\f487"; } +.bi-menu-button-wide-fill::before { content: "\f488"; } +.bi-menu-button-wide::before { content: "\f489"; } +.bi-menu-button::before { content: "\f48a"; } +.bi-menu-down::before { content: "\f48b"; } +.bi-menu-up::before { content: "\f48c"; } +.bi-mic-fill::before { content: "\f48d"; } +.bi-mic-mute-fill::before { content: "\f48e"; } +.bi-mic-mute::before { content: "\f48f"; } +.bi-mic::before { content: "\f490"; } +.bi-minecart-loaded::before { content: "\f491"; } +.bi-minecart::before { content: "\f492"; } +.bi-moisture::before { content: "\f493"; } +.bi-moon-fill::before { content: "\f494"; } +.bi-moon-stars-fill::before { content: "\f495"; } +.bi-moon-stars::before { content: "\f496"; } +.bi-moon::before { content: "\f497"; } +.bi-mouse-fill::before { content: "\f498"; } +.bi-mouse::before { content: "\f499"; } +.bi-mouse2-fill::before { content: "\f49a"; } +.bi-mouse2::before { content: "\f49b"; } +.bi-mouse3-fill::before { content: "\f49c"; } +.bi-mouse3::before { content: "\f49d"; } +.bi-music-note-beamed::before { content: "\f49e"; } +.bi-music-note-list::before { content: "\f49f"; } +.bi-music-note::before { content: "\f4a0"; } +.bi-music-player-fill::before { content: "\f4a1"; } +.bi-music-player::before { content: "\f4a2"; } +.bi-newspaper::before { content: "\f4a3"; } +.bi-node-minus-fill::before { content: "\f4a4"; } +.bi-node-minus::before { content: "\f4a5"; } +.bi-node-plus-fill::before { content: "\f4a6"; } +.bi-node-plus::before { content: "\f4a7"; } +.bi-nut-fill::before { content: "\f4a8"; } +.bi-nut::before { content: "\f4a9"; } +.bi-octagon-fill::before { content: "\f4aa"; } +.bi-octagon-half::before { content: "\f4ab"; } +.bi-octagon::before { content: "\f4ac"; } +.bi-option::before { content: "\f4ad"; } +.bi-outlet::before { content: "\f4ae"; } +.bi-paint-bucket::before { content: "\f4af"; } +.bi-palette-fill::before { content: "\f4b0"; } +.bi-palette::before { content: "\f4b1"; } +.bi-palette2::before { content: "\f4b2"; } +.bi-paperclip::before { content: "\f4b3"; } +.bi-paragraph::before { content: "\f4b4"; } +.bi-patch-check-fill::before { content: "\f4b5"; } +.bi-patch-check::before { content: "\f4b6"; } +.bi-patch-exclamation-fill::before { content: "\f4b7"; } +.bi-patch-exclamation::before { content: "\f4b8"; } +.bi-patch-minus-fill::before { content: "\f4b9"; } +.bi-patch-minus::before { content: "\f4ba"; } +.bi-patch-plus-fill::before { content: "\f4bb"; } +.bi-patch-plus::before { content: "\f4bc"; } +.bi-patch-question-fill::before { content: "\f4bd"; } +.bi-patch-question::before { content: "\f4be"; } +.bi-pause-btn-fill::before { content: "\f4bf"; } +.bi-pause-btn::before { content: "\f4c0"; } +.bi-pause-circle-fill::before { content: "\f4c1"; } +.bi-pause-circle::before { content: "\f4c2"; } +.bi-pause-fill::before { content: "\f4c3"; } +.bi-pause::before { content: "\f4c4"; } +.bi-peace-fill::before { content: "\f4c5"; } +.bi-peace::before { content: "\f4c6"; } +.bi-pen-fill::before { content: "\f4c7"; } +.bi-pen::before { content: "\f4c8"; } +.bi-pencil-fill::before { content: "\f4c9"; } +.bi-pencil-square::before { content: "\f4ca"; } +.bi-pencil::before { content: "\f4cb"; } +.bi-pentagon-fill::before { content: "\f4cc"; } +.bi-pentagon-half::before { content: "\f4cd"; } +.bi-pentagon::before { content: "\f4ce"; } +.bi-people-fill::before { content: "\f4cf"; } +.bi-people::before { content: "\f4d0"; } +.bi-percent::before { content: "\f4d1"; } +.bi-person-badge-fill::before { content: "\f4d2"; } +.bi-person-badge::before { content: "\f4d3"; } +.bi-person-bounding-box::before { content: "\f4d4"; } +.bi-person-check-fill::before { content: "\f4d5"; } +.bi-person-check::before { content: "\f4d6"; } +.bi-person-circle::before { content: "\f4d7"; } +.bi-person-dash-fill::before { content: "\f4d8"; } +.bi-person-dash::before { content: "\f4d9"; } +.bi-person-fill::before { content: "\f4da"; } +.bi-person-lines-fill::before { content: "\f4db"; } +.bi-person-plus-fill::before { content: "\f4dc"; } +.bi-person-plus::before { content: "\f4dd"; } +.bi-person-square::before { content: "\f4de"; } +.bi-person-x-fill::before { content: "\f4df"; } +.bi-person-x::before { content: "\f4e0"; } +.bi-person::before { content: "\f4e1"; } +.bi-phone-fill::before { content: "\f4e2"; } +.bi-phone-landscape-fill::before { content: "\f4e3"; } +.bi-phone-landscape::before { content: "\f4e4"; } +.bi-phone-vibrate-fill::before { content: "\f4e5"; } +.bi-phone-vibrate::before { content: "\f4e6"; } +.bi-phone::before { content: "\f4e7"; } +.bi-pie-chart-fill::before { content: "\f4e8"; } +.bi-pie-chart::before { content: "\f4e9"; } +.bi-pin-angle-fill::before { content: "\f4ea"; } +.bi-pin-angle::before { content: "\f4eb"; } +.bi-pin-fill::before { content: "\f4ec"; } +.bi-pin::before { content: "\f4ed"; } +.bi-pip-fill::before { content: "\f4ee"; } +.bi-pip::before { content: "\f4ef"; } +.bi-play-btn-fill::before { content: "\f4f0"; } +.bi-play-btn::before { content: "\f4f1"; } +.bi-play-circle-fill::before { content: "\f4f2"; } +.bi-play-circle::before { content: "\f4f3"; } +.bi-play-fill::before { content: "\f4f4"; } +.bi-play::before { content: "\f4f5"; } +.bi-plug-fill::before { content: "\f4f6"; } +.bi-plug::before { content: "\f4f7"; } +.bi-plus-circle-dotted::before { content: "\f4f8"; } +.bi-plus-circle-fill::before { content: "\f4f9"; } +.bi-plus-circle::before { content: "\f4fa"; } +.bi-plus-square-dotted::before { content: "\f4fb"; } +.bi-plus-square-fill::before { content: "\f4fc"; } +.bi-plus-square::before { content: "\f4fd"; } +.bi-plus::before { content: "\f4fe"; } +.bi-power::before { content: "\f4ff"; } +.bi-printer-fill::before { content: "\f500"; } +.bi-printer::before { content: "\f501"; } +.bi-puzzle-fill::before { content: "\f502"; } +.bi-puzzle::before { content: "\f503"; } +.bi-question-circle-fill::before { content: "\f504"; } +.bi-question-circle::before { content: "\f505"; } +.bi-question-diamond-fill::before { content: "\f506"; } +.bi-question-diamond::before { content: "\f507"; } +.bi-question-octagon-fill::before { content: "\f508"; } +.bi-question-octagon::before { content: "\f509"; } +.bi-question-square-fill::before { content: "\f50a"; } +.bi-question-square::before { content: "\f50b"; } +.bi-question::before { content: "\f50c"; } +.bi-rainbow::before { content: "\f50d"; } +.bi-receipt-cutoff::before { content: "\f50e"; } +.bi-receipt::before { content: "\f50f"; } +.bi-reception-0::before { content: "\f510"; } +.bi-reception-1::before { content: "\f511"; } +.bi-reception-2::before { content: "\f512"; } +.bi-reception-3::before { content: "\f513"; } +.bi-reception-4::before { content: "\f514"; } +.bi-record-btn-fill::before { content: "\f515"; } +.bi-record-btn::before { content: "\f516"; } +.bi-record-circle-fill::before { content: "\f517"; } +.bi-record-circle::before { content: "\f518"; } +.bi-record-fill::before { content: "\f519"; } +.bi-record::before { content: "\f51a"; } +.bi-record2-fill::before { content: "\f51b"; } +.bi-record2::before { content: "\f51c"; } +.bi-reply-all-fill::before { content: "\f51d"; } +.bi-reply-all::before { content: "\f51e"; } +.bi-reply-fill::before { content: "\f51f"; } +.bi-reply::before { content: "\f520"; } +.bi-rss-fill::before { content: "\f521"; } +.bi-rss::before { content: "\f522"; } +.bi-rulers::before { content: "\f523"; } +.bi-save-fill::before { content: "\f524"; } +.bi-save::before { content: "\f525"; } +.bi-save2-fill::before { content: "\f526"; } +.bi-save2::before { content: "\f527"; } +.bi-scissors::before { content: "\f528"; } +.bi-screwdriver::before { content: "\f529"; } +.bi-search::before { content: "\f52a"; } +.bi-segmented-nav::before { content: "\f52b"; } +.bi-server::before { content: "\f52c"; } +.bi-share-fill::before { content: "\f52d"; } +.bi-share::before { content: "\f52e"; } +.bi-shield-check::before { content: "\f52f"; } +.bi-shield-exclamation::before { content: "\f530"; } +.bi-shield-fill-check::before { content: "\f531"; } +.bi-shield-fill-exclamation::before { content: "\f532"; } +.bi-shield-fill-minus::before { content: "\f533"; } +.bi-shield-fill-plus::before { content: "\f534"; } +.bi-shield-fill-x::before { content: "\f535"; } +.bi-shield-fill::before { content: "\f536"; } +.bi-shield-lock-fill::before { content: "\f537"; } +.bi-shield-lock::before { content: "\f538"; } +.bi-shield-minus::before { content: "\f539"; } +.bi-shield-plus::before { content: "\f53a"; } +.bi-shield-shaded::before { content: "\f53b"; } +.bi-shield-slash-fill::before { content: "\f53c"; } +.bi-shield-slash::before { content: "\f53d"; } +.bi-shield-x::before { content: "\f53e"; } +.bi-shield::before { content: "\f53f"; } +.bi-shift-fill::before { content: "\f540"; } +.bi-shift::before { content: "\f541"; } +.bi-shop-window::before { content: "\f542"; } +.bi-shop::before { content: "\f543"; } +.bi-shuffle::before { content: "\f544"; } +.bi-signpost-2-fill::before { content: "\f545"; } +.bi-signpost-2::before { content: "\f546"; } +.bi-signpost-fill::before { content: "\f547"; } +.bi-signpost-split-fill::before { content: "\f548"; } +.bi-signpost-split::before { content: "\f549"; } +.bi-signpost::before { content: "\f54a"; } +.bi-sim-fill::before { content: "\f54b"; } +.bi-sim::before { content: "\f54c"; } +.bi-skip-backward-btn-fill::before { content: "\f54d"; } +.bi-skip-backward-btn::before { content: "\f54e"; } +.bi-skip-backward-circle-fill::before { content: "\f54f"; } +.bi-skip-backward-circle::before { content: "\f550"; } +.bi-skip-backward-fill::before { content: "\f551"; } +.bi-skip-backward::before { content: "\f552"; } +.bi-skip-end-btn-fill::before { content: "\f553"; } +.bi-skip-end-btn::before { content: "\f554"; } +.bi-skip-end-circle-fill::before { content: "\f555"; } +.bi-skip-end-circle::before { content: "\f556"; } +.bi-skip-end-fill::before { content: "\f557"; } +.bi-skip-end::before { content: "\f558"; } +.bi-skip-forward-btn-fill::before { content: "\f559"; } +.bi-skip-forward-btn::before { content: "\f55a"; } +.bi-skip-forward-circle-fill::before { content: "\f55b"; } +.bi-skip-forward-circle::before { content: "\f55c"; } +.bi-skip-forward-fill::before { content: "\f55d"; } +.bi-skip-forward::before { content: "\f55e"; } +.bi-skip-start-btn-fill::before { content: "\f55f"; } +.bi-skip-start-btn::before { content: "\f560"; } +.bi-skip-start-circle-fill::before { content: "\f561"; } +.bi-skip-start-circle::before { content: "\f562"; } +.bi-skip-start-fill::before { content: "\f563"; } +.bi-skip-start::before { content: "\f564"; } +.bi-slack::before { content: "\f565"; } +.bi-slash-circle-fill::before { content: "\f566"; } +.bi-slash-circle::before { content: "\f567"; } +.bi-slash-square-fill::before { content: "\f568"; } +.bi-slash-square::before { content: "\f569"; } +.bi-slash::before { content: "\f56a"; } +.bi-sliders::before { content: "\f56b"; } +.bi-smartwatch::before { content: "\f56c"; } +.bi-snow::before { content: "\f56d"; } +.bi-snow2::before { content: "\f56e"; } +.bi-snow3::before { content: "\f56f"; } +.bi-sort-alpha-down-alt::before { content: "\f570"; } +.bi-sort-alpha-down::before { content: "\f571"; } +.bi-sort-alpha-up-alt::before { content: "\f572"; } +.bi-sort-alpha-up::before { content: "\f573"; } +.bi-sort-down-alt::before { content: "\f574"; } +.bi-sort-down::before { content: "\f575"; } +.bi-sort-numeric-down-alt::before { content: "\f576"; } +.bi-sort-numeric-down::before { content: "\f577"; } +.bi-sort-numeric-up-alt::before { content: "\f578"; } +.bi-sort-numeric-up::before { content: "\f579"; } +.bi-sort-up-alt::before { content: "\f57a"; } +.bi-sort-up::before { content: "\f57b"; } +.bi-soundwave::before { content: "\f57c"; } +.bi-speaker-fill::before { content: "\f57d"; } +.bi-speaker::before { content: "\f57e"; } +.bi-speedometer::before { content: "\f57f"; } +.bi-speedometer2::before { content: "\f580"; } +.bi-spellcheck::before { content: "\f581"; } +.bi-square-fill::before { content: "\f582"; } +.bi-square-half::before { content: "\f583"; } +.bi-square::before { content: "\f584"; } +.bi-stack::before { content: "\f585"; } +.bi-star-fill::before { content: "\f586"; } +.bi-star-half::before { content: "\f587"; } +.bi-star::before { content: "\f588"; } +.bi-stars::before { content: "\f589"; } +.bi-stickies-fill::before { content: "\f58a"; } +.bi-stickies::before { content: "\f58b"; } +.bi-sticky-fill::before { content: "\f58c"; } +.bi-sticky::before { content: "\f58d"; } +.bi-stop-btn-fill::before { content: "\f58e"; } +.bi-stop-btn::before { content: "\f58f"; } +.bi-stop-circle-fill::before { content: "\f590"; } +.bi-stop-circle::before { content: "\f591"; } +.bi-stop-fill::before { content: "\f592"; } +.bi-stop::before { content: "\f593"; } +.bi-stoplights-fill::before { content: "\f594"; } +.bi-stoplights::before { content: "\f595"; } +.bi-stopwatch-fill::before { content: "\f596"; } +.bi-stopwatch::before { content: "\f597"; } +.bi-subtract::before { content: "\f598"; } +.bi-suit-club-fill::before { content: "\f599"; } +.bi-suit-club::before { content: "\f59a"; } +.bi-suit-diamond-fill::before { content: "\f59b"; } +.bi-suit-diamond::before { content: "\f59c"; } +.bi-suit-heart-fill::before { content: "\f59d"; } +.bi-suit-heart::before { content: "\f59e"; } +.bi-suit-spade-fill::before { content: "\f59f"; } +.bi-suit-spade::before { content: "\f5a0"; } +.bi-sun-fill::before { content: "\f5a1"; } +.bi-sun::before { content: "\f5a2"; } +.bi-sunglasses::before { content: "\f5a3"; } +.bi-sunrise-fill::before { content: "\f5a4"; } +.bi-sunrise::before { content: "\f5a5"; } +.bi-sunset-fill::before { content: "\f5a6"; } +.bi-sunset::before { content: "\f5a7"; } +.bi-symmetry-horizontal::before { content: "\f5a8"; } +.bi-symmetry-vertical::before { content: "\f5a9"; } +.bi-table::before { content: "\f5aa"; } +.bi-tablet-fill::before { content: "\f5ab"; } +.bi-tablet-landscape-fill::before { content: "\f5ac"; } +.bi-tablet-landscape::before { content: "\f5ad"; } +.bi-tablet::before { content: "\f5ae"; } +.bi-tag-fill::before { content: "\f5af"; } +.bi-tag::before { content: "\f5b0"; } +.bi-tags-fill::before { content: "\f5b1"; } +.bi-tags::before { content: "\f5b2"; } +.bi-telegram::before { content: "\f5b3"; } +.bi-telephone-fill::before { content: "\f5b4"; } +.bi-telephone-forward-fill::before { content: "\f5b5"; } +.bi-telephone-forward::before { content: "\f5b6"; } +.bi-telephone-inbound-fill::before { content: "\f5b7"; } +.bi-telephone-inbound::before { content: "\f5b8"; } +.bi-telephone-minus-fill::before { content: "\f5b9"; } +.bi-telephone-minus::before { content: "\f5ba"; } +.bi-telephone-outbound-fill::before { content: "\f5bb"; } +.bi-telephone-outbound::before { content: "\f5bc"; } +.bi-telephone-plus-fill::before { content: "\f5bd"; } +.bi-telephone-plus::before { content: "\f5be"; } +.bi-telephone-x-fill::before { content: "\f5bf"; } +.bi-telephone-x::before { content: "\f5c0"; } +.bi-telephone::before { content: "\f5c1"; } +.bi-terminal-fill::before { content: "\f5c2"; } +.bi-terminal::before { content: "\f5c3"; } +.bi-text-center::before { content: "\f5c4"; } +.bi-text-indent-left::before { content: "\f5c5"; } +.bi-text-indent-right::before { content: "\f5c6"; } +.bi-text-left::before { content: "\f5c7"; } +.bi-text-paragraph::before { content: "\f5c8"; } +.bi-text-right::before { content: "\f5c9"; } +.bi-textarea-resize::before { content: "\f5ca"; } +.bi-textarea-t::before { content: "\f5cb"; } +.bi-textarea::before { content: "\f5cc"; } +.bi-thermometer-half::before { content: "\f5cd"; } +.bi-thermometer-high::before { content: "\f5ce"; } +.bi-thermometer-low::before { content: "\f5cf"; } +.bi-thermometer-snow::before { content: "\f5d0"; } +.bi-thermometer-sun::before { content: "\f5d1"; } +.bi-thermometer::before { content: "\f5d2"; } +.bi-three-dots-vertical::before { content: "\f5d3"; } +.bi-three-dots::before { content: "\f5d4"; } +.bi-toggle-off::before { content: "\f5d5"; } +.bi-toggle-on::before { content: "\f5d6"; } +.bi-toggle2-off::before { content: "\f5d7"; } +.bi-toggle2-on::before { content: "\f5d8"; } +.bi-toggles::before { content: "\f5d9"; } +.bi-toggles2::before { content: "\f5da"; } +.bi-tools::before { content: "\f5db"; } +.bi-tornado::before { content: "\f5dc"; } +.bi-trash-fill::before { content: "\f5dd"; } +.bi-trash::before { content: "\f5de"; } +.bi-trash2-fill::before { content: "\f5df"; } +.bi-trash2::before { content: "\f5e0"; } +.bi-tree-fill::before { content: "\f5e1"; } +.bi-tree::before { content: "\f5e2"; } +.bi-triangle-fill::before { content: "\f5e3"; } +.bi-triangle-half::before { content: "\f5e4"; } +.bi-triangle::before { content: "\f5e5"; } +.bi-trophy-fill::before { content: "\f5e6"; } +.bi-trophy::before { content: "\f5e7"; } +.bi-tropical-storm::before { content: "\f5e8"; } +.bi-truck-flatbed::before { content: "\f5e9"; } +.bi-truck::before { content: "\f5ea"; } +.bi-tsunami::before { content: "\f5eb"; } +.bi-tv-fill::before { content: "\f5ec"; } +.bi-tv::before { content: "\f5ed"; } +.bi-twitch::before { content: "\f5ee"; } +.bi-twitter::before { content: "\f5ef"; } +.bi-type-bold::before { content: "\f5f0"; } +.bi-type-h1::before { content: "\f5f1"; } +.bi-type-h2::before { content: "\f5f2"; } +.bi-type-h3::before { content: "\f5f3"; } +.bi-type-italic::before { content: "\f5f4"; } +.bi-type-strikethrough::before { content: "\f5f5"; } +.bi-type-underline::before { content: "\f5f6"; } +.bi-type::before { content: "\f5f7"; } +.bi-ui-checks-grid::before { content: "\f5f8"; } +.bi-ui-checks::before { content: "\f5f9"; } +.bi-ui-radios-grid::before { content: "\f5fa"; } +.bi-ui-radios::before { content: "\f5fb"; } +.bi-umbrella-fill::before { content: "\f5fc"; } +.bi-umbrella::before { content: "\f5fd"; } +.bi-union::before { content: "\f5fe"; } +.bi-unlock-fill::before { content: "\f5ff"; } +.bi-unlock::before { content: "\f600"; } +.bi-upc-scan::before { content: "\f601"; } +.bi-upc::before { content: "\f602"; } +.bi-upload::before { content: "\f603"; } +.bi-vector-pen::before { content: "\f604"; } +.bi-view-list::before { content: "\f605"; } +.bi-view-stacked::before { content: "\f606"; } +.bi-vinyl-fill::before { content: "\f607"; } +.bi-vinyl::before { content: "\f608"; } +.bi-voicemail::before { content: "\f609"; } +.bi-volume-down-fill::before { content: "\f60a"; } +.bi-volume-down::before { content: "\f60b"; } +.bi-volume-mute-fill::before { content: "\f60c"; } +.bi-volume-mute::before { content: "\f60d"; } +.bi-volume-off-fill::before { content: "\f60e"; } +.bi-volume-off::before { content: "\f60f"; } +.bi-volume-up-fill::before { content: "\f610"; } +.bi-volume-up::before { content: "\f611"; } +.bi-vr::before { content: "\f612"; } +.bi-wallet-fill::before { content: "\f613"; } +.bi-wallet::before { content: "\f614"; } +.bi-wallet2::before { content: "\f615"; } +.bi-watch::before { content: "\f616"; } +.bi-water::before { content: "\f617"; } +.bi-whatsapp::before { content: "\f618"; } +.bi-wifi-1::before { content: "\f619"; } +.bi-wifi-2::before { content: "\f61a"; } +.bi-wifi-off::before { content: "\f61b"; } +.bi-wifi::before { content: "\f61c"; } +.bi-wind::before { content: "\f61d"; } +.bi-window-dock::before { content: "\f61e"; } +.bi-window-sidebar::before { content: "\f61f"; } +.bi-window::before { content: "\f620"; } +.bi-wrench::before { content: "\f621"; } +.bi-x-circle-fill::before { content: "\f622"; } +.bi-x-circle::before { content: "\f623"; } +.bi-x-diamond-fill::before { content: "\f624"; } +.bi-x-diamond::before { content: "\f625"; } +.bi-x-octagon-fill::before { content: "\f626"; } +.bi-x-octagon::before { content: "\f627"; } +.bi-x-square-fill::before { content: "\f628"; } +.bi-x-square::before { content: "\f629"; } +.bi-x::before { content: "\f62a"; } +.bi-youtube::before { content: "\f62b"; } +.bi-zoom-in::before { content: "\f62c"; } +.bi-zoom-out::before { content: "\f62d"; } +.bi-bank::before { content: "\f62e"; } +.bi-bank2::before { content: "\f62f"; } +.bi-bell-slash-fill::before { content: "\f630"; } +.bi-bell-slash::before { content: "\f631"; } +.bi-cash-coin::before { content: "\f632"; } +.bi-check-lg::before { content: "\f633"; } +.bi-coin::before { content: "\f634"; } +.bi-currency-bitcoin::before { content: "\f635"; } +.bi-currency-dollar::before { content: "\f636"; } +.bi-currency-euro::before { content: "\f637"; } +.bi-currency-exchange::before { content: "\f638"; } +.bi-currency-pound::before { content: "\f639"; } +.bi-currency-yen::before { content: "\f63a"; } +.bi-dash-lg::before { content: "\f63b"; } +.bi-exclamation-lg::before { content: "\f63c"; } +.bi-file-earmark-pdf-fill::before { content: "\f63d"; } +.bi-file-earmark-pdf::before { content: "\f63e"; } +.bi-file-pdf-fill::before { content: "\f63f"; } +.bi-file-pdf::before { content: "\f640"; } +.bi-gender-ambiguous::before { content: "\f641"; } +.bi-gender-female::before { content: "\f642"; } +.bi-gender-male::before { content: "\f643"; } +.bi-gender-trans::before { content: "\f644"; } +.bi-headset-vr::before { content: "\f645"; } +.bi-info-lg::before { content: "\f646"; } +.bi-mastodon::before { content: "\f647"; } +.bi-messenger::before { content: "\f648"; } +.bi-piggy-bank-fill::before { content: "\f649"; } +.bi-piggy-bank::before { content: "\f64a"; } +.bi-pin-map-fill::before { content: "\f64b"; } +.bi-pin-map::before { content: "\f64c"; } +.bi-plus-lg::before { content: "\f64d"; } +.bi-question-lg::before { content: "\f64e"; } +.bi-recycle::before { content: "\f64f"; } +.bi-reddit::before { content: "\f650"; } +.bi-safe-fill::before { content: "\f651"; } +.bi-safe2-fill::before { content: "\f652"; } +.bi-safe2::before { content: "\f653"; } +.bi-sd-card-fill::before { content: "\f654"; } +.bi-sd-card::before { content: "\f655"; } +.bi-skype::before { content: "\f656"; } +.bi-slash-lg::before { content: "\f657"; } +.bi-translate::before { content: "\f658"; } +.bi-x-lg::before { content: "\f659"; } +.bi-safe::before { content: "\f65a"; } diff --git a/src/css/bootstrap.min.css b/src/css/bootstrap.min.css new file mode 100644 index 0000000..45cbbe8 --- /dev/null +++ b/src/css/bootstrap.min.css @@ -0,0 +1,7 @@ +@charset "UTF-8";/*! + * Bootstrap v5.1.1 (https://getbootstrap.com/) + * Copyright 2011-2021 The Bootstrap Authors + * Copyright 2011-2021 Twitter, Inc. + * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) + */:root{--bs-blue:#3a72bd;--bs-indigo:#6610f2;--bs-purple:#6f42c1;--bs-pink:#d63384;--bs-red:#dc3545;--bs-orange:#fd7e14;--bs-yellow:#edaa16;--bs-green:#30aa5b;--bs-teal:#20c997;--bs-cyan:#17a2b8;--bs-white:#fff;--bs-gray:#6c757d;--bs-gray-dark:#343a40;--bs-gray-100:#f8f9fa;--bs-gray-200:#e9ecef;--bs-gray-300:#dee2e6;--bs-gray-400:#ced4da;--bs-gray-500:#adb5bd;--bs-gray-600:#6c757d;--bs-gray-700:#495057;--bs-gray-800:#343a40;--bs-gray-900:#212529;--bs-primary:#3a72bd;--bs-secondary:#6c757d;--bs-success:#30aa5b;--bs-info:#17a2b8;--bs-warning:#edaa16;--bs-danger:#dc3545;--bs-light:#f8f9fa;--bs-dark:#212529;--bs-primary-rgb:58,114,189;--bs-secondary-rgb:108,117,125;--bs-success-rgb:48,170,91;--bs-info-rgb:23,162,184;--bs-warning-rgb:237,170,22;--bs-danger-rgb:220,53,69;--bs-light-rgb:248,249,250;--bs-dark-rgb:33,37,41;--bs-white-rgb:255,255,255;--bs-black-rgb:0,0,0;--bs-body-color-rgb:33,37,41;--bs-body-bg-rgb:255,255,255;--bs-font-sans-serif:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans","Liberation Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--bs-font-monospace:SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--bs-gradient:linear-gradient(180deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0));--bs-body-font-family:var(--bs-font-sans-serif);--bs-body-font-size:1rem;--bs-body-font-weight:400;--bs-body-line-height:1.5;--bs-body-color:#212529;--bs-body-bg:#fff}*,::after,::before{box-sizing:border-box}@media (prefers-reduced-motion:no-preference){:root{scroll-behavior:smooth}}body{margin:0;font-family:var(--bs-body-font-family);font-size:var(--bs-body-font-size);font-weight:var(--bs-body-font-weight);line-height:var(--bs-body-line-height);color:var(--bs-body-color);text-align:var(--bs-body-text-align);background-color:var(--bs-body-bg);-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}hr{margin:1rem 0;color:inherit;background-color:currentColor;border:0;opacity:.25}hr:not([size]){height:1px}.h1,.h2,.h3,.h4,.h5,.h6,h1,h2,h3,h4,h5,h6{margin-top:0;margin-bottom:.5rem;font-weight:500;line-height:1.2}.h1,h1{font-size:calc(1.375rem + 1.5vw)}@media (min-width:1200px){.h1,h1{font-size:2.5rem}}.h2,h2{font-size:calc(1.325rem + .9vw)}@media (min-width:1200px){.h2,h2{font-size:2rem}}.h3,h3{font-size:calc(1.3rem + .6vw)}@media (min-width:1200px){.h3,h3{font-size:1.75rem}}.h4,h4{font-size:calc(1.275rem + .3vw)}@media (min-width:1200px){.h4,h4{font-size:1.5rem}}.h5,h5{font-size:1.25rem}.h6,h6{font-size:1rem}p{margin-top:0;margin-bottom:1rem}abbr[data-bs-original-title],abbr[title]{-webkit-text-decoration:underline dotted;text-decoration:underline dotted;cursor:help;-webkit-text-decoration-skip-ink:none;text-decoration-skip-ink:none}address{margin-bottom:1rem;font-style:normal;line-height:inherit}ol,ul{padding-left:2rem}dl,ol,ul{margin-top:0;margin-bottom:1rem}ol ol,ol ul,ul ol,ul ul{margin-bottom:0}dt{font-weight:700}dd{margin-bottom:.5rem;margin-left:0}blockquote{margin:0 0 1rem}b,strong{font-weight:bolder}.small,small{font-size:.875em}.mark,mark{padding:.2em;background-color:#fcf8e3}sub,sup{position:relative;font-size:.75em;line-height:0;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}a{color:#3a72bd;text-decoration:underline}a:hover{color:#2e5b97}a:not([href]):not([class]),a:not([href]):not([class]):hover{color:inherit;text-decoration:none}code,kbd,pre,samp{font-family:var(--bs-font-monospace);font-size:1em;direction:ltr;unicode-bidi:bidi-override}pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:.875em}pre code{font-size:inherit;color:inherit;word-break:normal}code{font-size:.875em;color:#d63384;word-wrap:break-word}a>code{color:inherit}kbd{padding:.2rem .4rem;font-size:.875em;color:#fff;background-color:#212529;border-radius:.2rem}kbd kbd{padding:0;font-size:1em;font-weight:700}figure{margin:0 0 1rem}img,svg{vertical-align:middle}table{caption-side:bottom;border-collapse:collapse}caption{padding-top:.5rem;padding-bottom:.5rem;color:#6c757d;text-align:left}th{text-align:inherit;text-align:-webkit-match-parent}tbody,td,tfoot,th,thead,tr{border-color:inherit;border-style:solid;border-width:0}label{display:inline-block}button{border-radius:0}button:focus:not(:focus-visible){outline:0}button,input,optgroup,select,textarea{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}button,select{text-transform:none}[role=button]{cursor:pointer}select{word-wrap:normal}select:disabled{opacity:1}[list]::-webkit-calendar-picker-indicator{display:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button}[type=button]:not(:disabled),[type=reset]:not(:disabled),[type=submit]:not(:disabled),button:not(:disabled){cursor:pointer}::-moz-focus-inner{padding:0;border-style:none}textarea{resize:vertical}fieldset{min-width:0;padding:0;margin:0;border:0}legend{float:left;width:100%;padding:0;margin-bottom:.5rem;font-size:calc(1.275rem + .3vw);line-height:inherit}@media (min-width:1200px){legend{font-size:1.5rem}}legend+*{clear:left}::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-fields-wrapper,::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-minute,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-text,::-webkit-datetime-edit-year-field{padding:0}::-webkit-inner-spin-button{height:auto}[type=search]{outline-offset:-2px;-webkit-appearance:textfield}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-color-swatch-wrapper{padding:0}::file-selector-button{font:inherit}::-webkit-file-upload-button{font:inherit;-webkit-appearance:button}output{display:inline-block}iframe{border:0}summary{display:list-item;cursor:pointer}progress{vertical-align:baseline}[hidden]{display:none!important}.lead{font-size:1.25rem;font-weight:300}.display-1{font-size:calc(1.625rem + 4.5vw);font-weight:300;line-height:1.2}@media (min-width:1200px){.display-1{font-size:5rem}}.display-2{font-size:calc(1.575rem + 3.9vw);font-weight:300;line-height:1.2}@media (min-width:1200px){.display-2{font-size:4.5rem}}.display-3{font-size:calc(1.525rem + 3.3vw);font-weight:300;line-height:1.2}@media (min-width:1200px){.display-3{font-size:4rem}}.display-4{font-size:calc(1.475rem + 2.7vw);font-weight:300;line-height:1.2}@media (min-width:1200px){.display-4{font-size:3.5rem}}.display-5{font-size:calc(1.425rem + 2.1vw);font-weight:300;line-height:1.2}@media (min-width:1200px){.display-5{font-size:3rem}}.display-6{font-size:calc(1.375rem + 1.5vw);font-weight:300;line-height:1.2}@media (min-width:1200px){.display-6{font-size:2.5rem}}.list-unstyled{padding-left:0;list-style:none}.list-inline{padding-left:0;list-style:none}.list-inline-item{display:inline-block}.list-inline-item:not(:last-child){margin-right:.5rem}.initialism{font-size:.875em;text-transform:uppercase}.blockquote{margin-bottom:1rem;font-size:1.25rem}.blockquote>:last-child{margin-bottom:0}.blockquote-footer{margin-top:-1rem;margin-bottom:1rem;font-size:.875em;color:#6c757d}.blockquote-footer::before{content:"— "}.img-fluid{max-width:100%;height:auto}.img-thumbnail{padding:.25rem;background-color:#fff;border:1px solid #dee2e6;border-radius:.25rem;max-width:100%;height:auto}.figure{display:inline-block}.figure-img{margin-bottom:.5rem;line-height:1}.figure-caption{font-size:.875em;color:#6c757d}.container,.container-fluid,.container-lg,.container-md,.container-sm,.container-xl,.container-xxl{width:100%;padding-right:var(--bs-gutter-x,.75rem);padding-left:var(--bs-gutter-x,.75rem);margin-right:auto;margin-left:auto}@media (min-width:576px){.container,.container-sm{max-width:540px}}@media (min-width:768px){.container,.container-md,.container-sm{max-width:720px}}@media (min-width:992px){.container,.container-lg,.container-md,.container-sm{max-width:960px}}@media (min-width:1200px){.container,.container-lg,.container-md,.container-sm,.container-xl{max-width:1140px}}@media (min-width:1400px){.container,.container-lg,.container-md,.container-sm,.container-xl,.container-xxl{max-width:1320px}}.row{--bs-gutter-x:1.5rem;--bs-gutter-y:0;display:flex;flex-wrap:wrap;margin-top:calc(var(--bs-gutter-y) * -1);margin-right:calc(var(--bs-gutter-x) * -.5);margin-left:calc(var(--bs-gutter-x) * -.5)}.row>*{flex-shrink:0;width:100%;max-width:100%;padding-right:calc(var(--bs-gutter-x) * .5);padding-left:calc(var(--bs-gutter-x) * .5);margin-top:var(--bs-gutter-y)}.col{flex:1 0 0%}.row-cols-auto>*{flex:0 0 auto;width:auto}.row-cols-1>*{flex:0 0 auto;width:100%}.row-cols-2>*{flex:0 0 auto;width:50%}.row-cols-3>*{flex:0 0 auto;width:33.3333333333%}.row-cols-4>*{flex:0 0 auto;width:25%}.row-cols-5>*{flex:0 0 auto;width:20%}.row-cols-6>*{flex:0 0 auto;width:16.6666666667%}.col-auto{flex:0 0 auto;width:auto}.col-1{flex:0 0 auto;width:8.33333333%}.col-2{flex:0 0 auto;width:16.66666667%}.col-3{flex:0 0 auto;width:25%}.col-4{flex:0 0 auto;width:33.33333333%}.col-5{flex:0 0 auto;width:41.66666667%}.col-6{flex:0 0 auto;width:50%}.col-7{flex:0 0 auto;width:58.33333333%}.col-8{flex:0 0 auto;width:66.66666667%}.col-9{flex:0 0 auto;width:75%}.col-10{flex:0 0 auto;width:83.33333333%}.col-11{flex:0 0 auto;width:91.66666667%}.col-12{flex:0 0 auto;width:100%}.offset-1{margin-left:8.33333333%}.offset-2{margin-left:16.66666667%}.offset-3{margin-left:25%}.offset-4{margin-left:33.33333333%}.offset-5{margin-left:41.66666667%}.offset-6{margin-left:50%}.offset-7{margin-left:58.33333333%}.offset-8{margin-left:66.66666667%}.offset-9{margin-left:75%}.offset-10{margin-left:83.33333333%}.offset-11{margin-left:91.66666667%}.g-0,.gx-0{--bs-gutter-x:0}.g-0,.gy-0{--bs-gutter-y:0}.g-1,.gx-1{--bs-gutter-x:0.25rem}.g-1,.gy-1{--bs-gutter-y:0.25rem}.g-2,.gx-2{--bs-gutter-x:0.5rem}.g-2,.gy-2{--bs-gutter-y:0.5rem}.g-3,.gx-3{--bs-gutter-x:1rem}.g-3,.gy-3{--bs-gutter-y:1rem}.g-4,.gx-4{--bs-gutter-x:1.5rem}.g-4,.gy-4{--bs-gutter-y:1.5rem}.g-5,.gx-5{--bs-gutter-x:3rem}.g-5,.gy-5{--bs-gutter-y:3rem}@media (min-width:576px){.col-sm{flex:1 0 0%}.row-cols-sm-auto>*{flex:0 0 auto;width:auto}.row-cols-sm-1>*{flex:0 0 auto;width:100%}.row-cols-sm-2>*{flex:0 0 auto;width:50%}.row-cols-sm-3>*{flex:0 0 auto;width:33.3333333333%}.row-cols-sm-4>*{flex:0 0 auto;width:25%}.row-cols-sm-5>*{flex:0 0 auto;width:20%}.row-cols-sm-6>*{flex:0 0 auto;width:16.6666666667%}.col-sm-auto{flex:0 0 auto;width:auto}.col-sm-1{flex:0 0 auto;width:8.33333333%}.col-sm-2{flex:0 0 auto;width:16.66666667%}.col-sm-3{flex:0 0 auto;width:25%}.col-sm-4{flex:0 0 auto;width:33.33333333%}.col-sm-5{flex:0 0 auto;width:41.66666667%}.col-sm-6{flex:0 0 auto;width:50%}.col-sm-7{flex:0 0 auto;width:58.33333333%}.col-sm-8{flex:0 0 auto;width:66.66666667%}.col-sm-9{flex:0 0 auto;width:75%}.col-sm-10{flex:0 0 auto;width:83.33333333%}.col-sm-11{flex:0 0 auto;width:91.66666667%}.col-sm-12{flex:0 0 auto;width:100%}.offset-sm-0{margin-left:0}.offset-sm-1{margin-left:8.33333333%}.offset-sm-2{margin-left:16.66666667%}.offset-sm-3{margin-left:25%}.offset-sm-4{margin-left:33.33333333%}.offset-sm-5{margin-left:41.66666667%}.offset-sm-6{margin-left:50%}.offset-sm-7{margin-left:58.33333333%}.offset-sm-8{margin-left:66.66666667%}.offset-sm-9{margin-left:75%}.offset-sm-10{margin-left:83.33333333%}.offset-sm-11{margin-left:91.66666667%}.g-sm-0,.gx-sm-0{--bs-gutter-x:0}.g-sm-0,.gy-sm-0{--bs-gutter-y:0}.g-sm-1,.gx-sm-1{--bs-gutter-x:0.25rem}.g-sm-1,.gy-sm-1{--bs-gutter-y:0.25rem}.g-sm-2,.gx-sm-2{--bs-gutter-x:0.5rem}.g-sm-2,.gy-sm-2{--bs-gutter-y:0.5rem}.g-sm-3,.gx-sm-3{--bs-gutter-x:1rem}.g-sm-3,.gy-sm-3{--bs-gutter-y:1rem}.g-sm-4,.gx-sm-4{--bs-gutter-x:1.5rem}.g-sm-4,.gy-sm-4{--bs-gutter-y:1.5rem}.g-sm-5,.gx-sm-5{--bs-gutter-x:3rem}.g-sm-5,.gy-sm-5{--bs-gutter-y:3rem}}@media (min-width:768px){.col-md{flex:1 0 0%}.row-cols-md-auto>*{flex:0 0 auto;width:auto}.row-cols-md-1>*{flex:0 0 auto;width:100%}.row-cols-md-2>*{flex:0 0 auto;width:50%}.row-cols-md-3>*{flex:0 0 auto;width:33.3333333333%}.row-cols-md-4>*{flex:0 0 auto;width:25%}.row-cols-md-5>*{flex:0 0 auto;width:20%}.row-cols-md-6>*{flex:0 0 auto;width:16.6666666667%}.col-md-auto{flex:0 0 auto;width:auto}.col-md-1{flex:0 0 auto;width:8.33333333%}.col-md-2{flex:0 0 auto;width:16.66666667%}.col-md-3{flex:0 0 auto;width:25%}.col-md-4{flex:0 0 auto;width:33.33333333%}.col-md-5{flex:0 0 auto;width:41.66666667%}.col-md-6{flex:0 0 auto;width:50%}.col-md-7{flex:0 0 auto;width:58.33333333%}.col-md-8{flex:0 0 auto;width:66.66666667%}.col-md-9{flex:0 0 auto;width:75%}.col-md-10{flex:0 0 auto;width:83.33333333%}.col-md-11{flex:0 0 auto;width:91.66666667%}.col-md-12{flex:0 0 auto;width:100%}.offset-md-0{margin-left:0}.offset-md-1{margin-left:8.33333333%}.offset-md-2{margin-left:16.66666667%}.offset-md-3{margin-left:25%}.offset-md-4{margin-left:33.33333333%}.offset-md-5{margin-left:41.66666667%}.offset-md-6{margin-left:50%}.offset-md-7{margin-left:58.33333333%}.offset-md-8{margin-left:66.66666667%}.offset-md-9{margin-left:75%}.offset-md-10{margin-left:83.33333333%}.offset-md-11{margin-left:91.66666667%}.g-md-0,.gx-md-0{--bs-gutter-x:0}.g-md-0,.gy-md-0{--bs-gutter-y:0}.g-md-1,.gx-md-1{--bs-gutter-x:0.25rem}.g-md-1,.gy-md-1{--bs-gutter-y:0.25rem}.g-md-2,.gx-md-2{--bs-gutter-x:0.5rem}.g-md-2,.gy-md-2{--bs-gutter-y:0.5rem}.g-md-3,.gx-md-3{--bs-gutter-x:1rem}.g-md-3,.gy-md-3{--bs-gutter-y:1rem}.g-md-4,.gx-md-4{--bs-gutter-x:1.5rem}.g-md-4,.gy-md-4{--bs-gutter-y:1.5rem}.g-md-5,.gx-md-5{--bs-gutter-x:3rem}.g-md-5,.gy-md-5{--bs-gutter-y:3rem}}@media (min-width:992px){.col-lg{flex:1 0 0%}.row-cols-lg-auto>*{flex:0 0 auto;width:auto}.row-cols-lg-1>*{flex:0 0 auto;width:100%}.row-cols-lg-2>*{flex:0 0 auto;width:50%}.row-cols-lg-3>*{flex:0 0 auto;width:33.3333333333%}.row-cols-lg-4>*{flex:0 0 auto;width:25%}.row-cols-lg-5>*{flex:0 0 auto;width:20%}.row-cols-lg-6>*{flex:0 0 auto;width:16.6666666667%}.col-lg-auto{flex:0 0 auto;width:auto}.col-lg-1{flex:0 0 auto;width:8.33333333%}.col-lg-2{flex:0 0 auto;width:16.66666667%}.col-lg-3{flex:0 0 auto;width:25%}.col-lg-4{flex:0 0 auto;width:33.33333333%}.col-lg-5{flex:0 0 auto;width:41.66666667%}.col-lg-6{flex:0 0 auto;width:50%}.col-lg-7{flex:0 0 auto;width:58.33333333%}.col-lg-8{flex:0 0 auto;width:66.66666667%}.col-lg-9{flex:0 0 auto;width:75%}.col-lg-10{flex:0 0 auto;width:83.33333333%}.col-lg-11{flex:0 0 auto;width:91.66666667%}.col-lg-12{flex:0 0 auto;width:100%}.offset-lg-0{margin-left:0}.offset-lg-1{margin-left:8.33333333%}.offset-lg-2{margin-left:16.66666667%}.offset-lg-3{margin-left:25%}.offset-lg-4{margin-left:33.33333333%}.offset-lg-5{margin-left:41.66666667%}.offset-lg-6{margin-left:50%}.offset-lg-7{margin-left:58.33333333%}.offset-lg-8{margin-left:66.66666667%}.offset-lg-9{margin-left:75%}.offset-lg-10{margin-left:83.33333333%}.offset-lg-11{margin-left:91.66666667%}.g-lg-0,.gx-lg-0{--bs-gutter-x:0}.g-lg-0,.gy-lg-0{--bs-gutter-y:0}.g-lg-1,.gx-lg-1{--bs-gutter-x:0.25rem}.g-lg-1,.gy-lg-1{--bs-gutter-y:0.25rem}.g-lg-2,.gx-lg-2{--bs-gutter-x:0.5rem}.g-lg-2,.gy-lg-2{--bs-gutter-y:0.5rem}.g-lg-3,.gx-lg-3{--bs-gutter-x:1rem}.g-lg-3,.gy-lg-3{--bs-gutter-y:1rem}.g-lg-4,.gx-lg-4{--bs-gutter-x:1.5rem}.g-lg-4,.gy-lg-4{--bs-gutter-y:1.5rem}.g-lg-5,.gx-lg-5{--bs-gutter-x:3rem}.g-lg-5,.gy-lg-5{--bs-gutter-y:3rem}}@media (min-width:1200px){.col-xl{flex:1 0 0%}.row-cols-xl-auto>*{flex:0 0 auto;width:auto}.row-cols-xl-1>*{flex:0 0 auto;width:100%}.row-cols-xl-2>*{flex:0 0 auto;width:50%}.row-cols-xl-3>*{flex:0 0 auto;width:33.3333333333%}.row-cols-xl-4>*{flex:0 0 auto;width:25%}.row-cols-xl-5>*{flex:0 0 auto;width:20%}.row-cols-xl-6>*{flex:0 0 auto;width:16.6666666667%}.col-xl-auto{flex:0 0 auto;width:auto}.col-xl-1{flex:0 0 auto;width:8.33333333%}.col-xl-2{flex:0 0 auto;width:16.66666667%}.col-xl-3{flex:0 0 auto;width:25%}.col-xl-4{flex:0 0 auto;width:33.33333333%}.col-xl-5{flex:0 0 auto;width:41.66666667%}.col-xl-6{flex:0 0 auto;width:50%}.col-xl-7{flex:0 0 auto;width:58.33333333%}.col-xl-8{flex:0 0 auto;width:66.66666667%}.col-xl-9{flex:0 0 auto;width:75%}.col-xl-10{flex:0 0 auto;width:83.33333333%}.col-xl-11{flex:0 0 auto;width:91.66666667%}.col-xl-12{flex:0 0 auto;width:100%}.offset-xl-0{margin-left:0}.offset-xl-1{margin-left:8.33333333%}.offset-xl-2{margin-left:16.66666667%}.offset-xl-3{margin-left:25%}.offset-xl-4{margin-left:33.33333333%}.offset-xl-5{margin-left:41.66666667%}.offset-xl-6{margin-left:50%}.offset-xl-7{margin-left:58.33333333%}.offset-xl-8{margin-left:66.66666667%}.offset-xl-9{margin-left:75%}.offset-xl-10{margin-left:83.33333333%}.offset-xl-11{margin-left:91.66666667%}.g-xl-0,.gx-xl-0{--bs-gutter-x:0}.g-xl-0,.gy-xl-0{--bs-gutter-y:0}.g-xl-1,.gx-xl-1{--bs-gutter-x:0.25rem}.g-xl-1,.gy-xl-1{--bs-gutter-y:0.25rem}.g-xl-2,.gx-xl-2{--bs-gutter-x:0.5rem}.g-xl-2,.gy-xl-2{--bs-gutter-y:0.5rem}.g-xl-3,.gx-xl-3{--bs-gutter-x:1rem}.g-xl-3,.gy-xl-3{--bs-gutter-y:1rem}.g-xl-4,.gx-xl-4{--bs-gutter-x:1.5rem}.g-xl-4,.gy-xl-4{--bs-gutter-y:1.5rem}.g-xl-5,.gx-xl-5{--bs-gutter-x:3rem}.g-xl-5,.gy-xl-5{--bs-gutter-y:3rem}}@media (min-width:1400px){.col-xxl{flex:1 0 0%}.row-cols-xxl-auto>*{flex:0 0 auto;width:auto}.row-cols-xxl-1>*{flex:0 0 auto;width:100%}.row-cols-xxl-2>*{flex:0 0 auto;width:50%}.row-cols-xxl-3>*{flex:0 0 auto;width:33.3333333333%}.row-cols-xxl-4>*{flex:0 0 auto;width:25%}.row-cols-xxl-5>*{flex:0 0 auto;width:20%}.row-cols-xxl-6>*{flex:0 0 auto;width:16.6666666667%}.col-xxl-auto{flex:0 0 auto;width:auto}.col-xxl-1{flex:0 0 auto;width:8.33333333%}.col-xxl-2{flex:0 0 auto;width:16.66666667%}.col-xxl-3{flex:0 0 auto;width:25%}.col-xxl-4{flex:0 0 auto;width:33.33333333%}.col-xxl-5{flex:0 0 auto;width:41.66666667%}.col-xxl-6{flex:0 0 auto;width:50%}.col-xxl-7{flex:0 0 auto;width:58.33333333%}.col-xxl-8{flex:0 0 auto;width:66.66666667%}.col-xxl-9{flex:0 0 auto;width:75%}.col-xxl-10{flex:0 0 auto;width:83.33333333%}.col-xxl-11{flex:0 0 auto;width:91.66666667%}.col-xxl-12{flex:0 0 auto;width:100%}.offset-xxl-0{margin-left:0}.offset-xxl-1{margin-left:8.33333333%}.offset-xxl-2{margin-left:16.66666667%}.offset-xxl-3{margin-left:25%}.offset-xxl-4{margin-left:33.33333333%}.offset-xxl-5{margin-left:41.66666667%}.offset-xxl-6{margin-left:50%}.offset-xxl-7{margin-left:58.33333333%}.offset-xxl-8{margin-left:66.66666667%}.offset-xxl-9{margin-left:75%}.offset-xxl-10{margin-left:83.33333333%}.offset-xxl-11{margin-left:91.66666667%}.g-xxl-0,.gx-xxl-0{--bs-gutter-x:0}.g-xxl-0,.gy-xxl-0{--bs-gutter-y:0}.g-xxl-1,.gx-xxl-1{--bs-gutter-x:0.25rem}.g-xxl-1,.gy-xxl-1{--bs-gutter-y:0.25rem}.g-xxl-2,.gx-xxl-2{--bs-gutter-x:0.5rem}.g-xxl-2,.gy-xxl-2{--bs-gutter-y:0.5rem}.g-xxl-3,.gx-xxl-3{--bs-gutter-x:1rem}.g-xxl-3,.gy-xxl-3{--bs-gutter-y:1rem}.g-xxl-4,.gx-xxl-4{--bs-gutter-x:1.5rem}.g-xxl-4,.gy-xxl-4{--bs-gutter-y:1.5rem}.g-xxl-5,.gx-xxl-5{--bs-gutter-x:3rem}.g-xxl-5,.gy-xxl-5{--bs-gutter-y:3rem}}.table{--bs-table-bg:transparent;--bs-table-accent-bg:transparent;--bs-table-striped-color:#212529;--bs-table-striped-bg:rgba(0, 0, 0, 0.05);--bs-table-active-color:#212529;--bs-table-active-bg:rgba(0, 0, 0, 0.1);--bs-table-hover-color:#212529;--bs-table-hover-bg:rgba(0, 0, 0, 0.075);width:100%;margin-bottom:1rem;color:#212529;vertical-align:top;border-color:#dee2e6}.table>:not(caption)>*>*{padding:.5rem .5rem;background-color:var(--bs-table-bg);border-bottom-width:1px;box-shadow:inset 0 0 0 9999px var(--bs-table-accent-bg)}.table>tbody{vertical-align:inherit}.table>thead{vertical-align:bottom}.table>:not(:last-child)>:last-child>*{border-bottom-color:currentColor}.caption-top{caption-side:top}.table-sm>:not(caption)>*>*{padding:.25rem .25rem}.table-bordered>:not(caption)>*{border-width:1px 0}.table-bordered>:not(caption)>*>*{border-width:0 1px}.table-borderless>:not(caption)>*>*{border-bottom-width:0}.table-striped>tbody>tr:nth-of-type(odd){--bs-table-accent-bg:var(--bs-table-striped-bg);color:var(--bs-table-striped-color)}.table-active{--bs-table-accent-bg:var(--bs-table-active-bg);color:var(--bs-table-active-color)}.table-hover>tbody>tr:hover{--bs-table-accent-bg:var(--bs-table-hover-bg);color:var(--bs-table-hover-color)}.table-primary{--bs-table-bg:#d8e3f2;--bs-table-striped-bg:#cdd8e6;--bs-table-striped-color:#000;--bs-table-active-bg:#c2ccda;--bs-table-active-color:#000;--bs-table-hover-bg:#c8d2e0;--bs-table-hover-color:#000;color:#000;border-color:#c2ccda}.table-secondary{--bs-table-bg:#e2e3e5;--bs-table-striped-bg:#d7d8da;--bs-table-striped-color:#000;--bs-table-active-bg:#cbccce;--bs-table-active-color:#000;--bs-table-hover-bg:#d1d2d4;--bs-table-hover-color:#000;color:#000;border-color:#cbccce}.table-success{--bs-table-bg:#d6eede;--bs-table-striped-bg:#cbe2d3;--bs-table-striped-color:#000;--bs-table-active-bg:#c1d6c8;--bs-table-active-color:#000;--bs-table-hover-bg:#c6dccd;--bs-table-hover-color:#000;color:#000;border-color:#c1d6c8}.table-info{--bs-table-bg:#d1ecf1;--bs-table-striped-bg:#c7e0e5;--bs-table-striped-color:#000;--bs-table-active-bg:#bcd4d9;--bs-table-active-color:#000;--bs-table-hover-bg:#c1dadf;--bs-table-hover-color:#000;color:#000;border-color:#bcd4d9}.table-warning{--bs-table-bg:#fbeed0;--bs-table-striped-bg:#eee2c6;--bs-table-striped-color:#000;--bs-table-active-bg:#e2d6bb;--bs-table-active-color:#000;--bs-table-hover-bg:#e8dcc0;--bs-table-hover-color:#000;color:#000;border-color:#e2d6bb}.table-danger{--bs-table-bg:#f8d7da;--bs-table-striped-bg:#eccccf;--bs-table-striped-color:#000;--bs-table-active-bg:#dfc2c4;--bs-table-active-color:#000;--bs-table-hover-bg:#e5c7ca;--bs-table-hover-color:#000;color:#000;border-color:#dfc2c4}.table-light{--bs-table-bg:#f8f9fa;--bs-table-striped-bg:#ecedee;--bs-table-striped-color:#000;--bs-table-active-bg:#dfe0e1;--bs-table-active-color:#000;--bs-table-hover-bg:#e5e6e7;--bs-table-hover-color:#000;color:#000;border-color:#dfe0e1}.table-dark{--bs-table-bg:#212529;--bs-table-striped-bg:#2c3034;--bs-table-striped-color:#fff;--bs-table-active-bg:#373b3e;--bs-table-active-color:#fff;--bs-table-hover-bg:#323539;--bs-table-hover-color:#fff;color:#fff;border-color:#373b3e}.table-responsive{overflow-x:auto;-webkit-overflow-scrolling:touch}@media (max-width:575.98px){.table-responsive-sm{overflow-x:auto;-webkit-overflow-scrolling:touch}}@media (max-width:767.98px){.table-responsive-md{overflow-x:auto;-webkit-overflow-scrolling:touch}}@media (max-width:991.98px){.table-responsive-lg{overflow-x:auto;-webkit-overflow-scrolling:touch}}@media (max-width:1199.98px){.table-responsive-xl{overflow-x:auto;-webkit-overflow-scrolling:touch}}@media (max-width:1399.98px){.table-responsive-xxl{overflow-x:auto;-webkit-overflow-scrolling:touch}}.form-label{margin-bottom:.5rem}.col-form-label{padding-top:calc(.375rem + 1px);padding-bottom:calc(.375rem + 1px);margin-bottom:0;font-size:inherit;line-height:1.5}.col-form-label-lg{padding-top:calc(.5rem + 1px);padding-bottom:calc(.5rem + 1px);font-size:1.25rem}.col-form-label-sm{padding-top:calc(.25rem + 1px);padding-bottom:calc(.25rem + 1px);font-size:.875rem}.form-text{margin-top:.25rem;font-size:.875em;color:#6c757d}.form-control{display:block;width:100%;padding:.375rem .75rem;font-size:1rem;font-weight:400;line-height:1.5;color:#212529;background-color:#fff;background-clip:padding-box;border:1px solid #ced4da;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:.25rem;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out}@media (prefers-reduced-motion:reduce){.form-control{transition:none}}.form-control[type=file]{overflow:hidden}.form-control[type=file]:not(:disabled):not([readonly]){cursor:pointer}.form-control:focus{color:#212529;background-color:#fff;border-color:#9db9de;outline:0;box-shadow:0 0 0 .25rem rgba(58,114,189,.25)}.form-control::-webkit-date-and-time-value{height:1.5em}.form-control::-moz-placeholder{color:#6c757d;opacity:1}.form-control::placeholder{color:#6c757d;opacity:1}.form-control:disabled,.form-control[readonly]{background-color:#e9ecef;opacity:1}.form-control::file-selector-button{padding:.375rem .75rem;margin:-.375rem -.75rem;-webkit-margin-end:.75rem;margin-inline-end:.75rem;color:#212529;background-color:#e9ecef;pointer-events:none;border-color:inherit;border-style:solid;border-width:0;border-inline-end-width:1px;border-radius:0;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}@media (prefers-reduced-motion:reduce){.form-control::file-selector-button{transition:none}}.form-control:hover:not(:disabled):not([readonly])::file-selector-button{background-color:#dde0e3}.form-control::-webkit-file-upload-button{padding:.375rem .75rem;margin:-.375rem -.75rem;-webkit-margin-end:.75rem;margin-inline-end:.75rem;color:#212529;background-color:#e9ecef;pointer-events:none;border-color:inherit;border-style:solid;border-width:0;border-inline-end-width:1px;border-radius:0;-webkit-transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}@media (prefers-reduced-motion:reduce){.form-control::-webkit-file-upload-button{-webkit-transition:none;transition:none}}.form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button{background-color:#dde0e3}.form-control-plaintext{display:block;width:100%;padding:.375rem 0;margin-bottom:0;line-height:1.5;color:#212529;background-color:transparent;border:solid transparent;border-width:1px 0}.form-control-plaintext.form-control-lg,.form-control-plaintext.form-control-sm{padding-right:0;padding-left:0}.form-control-sm{min-height:calc(1.5em + .5rem + 2px);padding:.25rem .5rem;font-size:.875rem;border-radius:.2rem}.form-control-sm::file-selector-button{padding:.25rem .5rem;margin:-.25rem -.5rem;-webkit-margin-end:.5rem;margin-inline-end:.5rem}.form-control-sm::-webkit-file-upload-button{padding:.25rem .5rem;margin:-.25rem -.5rem;-webkit-margin-end:.5rem;margin-inline-end:.5rem}.form-control-lg{min-height:calc(1.5em + 1rem + 2px);padding:.5rem 1rem;font-size:1.25rem;border-radius:.3rem}.form-control-lg::file-selector-button{padding:.5rem 1rem;margin:-.5rem -1rem;-webkit-margin-end:1rem;margin-inline-end:1rem}.form-control-lg::-webkit-file-upload-button{padding:.5rem 1rem;margin:-.5rem -1rem;-webkit-margin-end:1rem;margin-inline-end:1rem}textarea.form-control{min-height:calc(1.5em + .75rem + 2px)}textarea.form-control-sm{min-height:calc(1.5em + .5rem + 2px)}textarea.form-control-lg{min-height:calc(1.5em + 1rem + 2px)}.form-control-color{width:3rem;height:auto;padding:.375rem}.form-control-color:not(:disabled):not([readonly]){cursor:pointer}.form-control-color::-moz-color-swatch{height:1.5em;border-radius:.25rem}.form-control-color::-webkit-color-swatch{height:1.5em;border-radius:.25rem}.form-select{display:block;width:100%;padding:.375rem 2.25rem .375rem .75rem;-moz-padding-start:calc(0.75rem - 3px);font-size:1rem;font-weight:400;line-height:1.5;color:#212529;background-color:#fff;background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");background-repeat:no-repeat;background-position:right .75rem center;background-size:16px 12px;border:1px solid #ced4da;border-radius:.25rem;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out;-webkit-appearance:none;-moz-appearance:none;appearance:none}@media (prefers-reduced-motion:reduce){.form-select{transition:none}}.form-select:focus{border-color:#9db9de;outline:0;box-shadow:0 0 0 .25rem rgba(58,114,189,.25)}.form-select[multiple],.form-select[size]:not([size="1"]){padding-right:.75rem;background-image:none}.form-select:disabled{background-color:#e9ecef}.form-select:-moz-focusring{color:transparent;text-shadow:0 0 0 #212529}.form-select-sm{padding-top:.25rem;padding-bottom:.25rem;padding-left:.5rem;font-size:.875rem}.form-select-lg{padding-top:.5rem;padding-bottom:.5rem;padding-left:1rem;font-size:1.25rem}.form-check{display:block;min-height:1.5rem;padding-left:1.5em;margin-bottom:.125rem}.form-check .form-check-input{float:left;margin-left:-1.5em}.form-check-input{width:1em;height:1em;margin-top:.25em;vertical-align:top;background-color:#fff;background-repeat:no-repeat;background-position:center;background-size:contain;border:1px solid rgba(0,0,0,.25);-webkit-appearance:none;-moz-appearance:none;appearance:none;-webkit-print-color-adjust:exact;color-adjust:exact}.form-check-input[type=checkbox]{border-radius:.25em}.form-check-input[type=radio]{border-radius:50%}.form-check-input:active{filter:brightness(90%)}.form-check-input:focus{border-color:#9db9de;outline:0;box-shadow:0 0 0 .25rem rgba(58,114,189,.25)}.form-check-input:checked{background-color:#3a72bd;border-color:#3a72bd}.form-check-input:checked[type=checkbox]{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='M6 10l3 3l6-6'/%3e%3c/svg%3e")}.form-check-input:checked[type=radio]{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='2' fill='%23fff'/%3e%3c/svg%3e")}.form-check-input[type=checkbox]:indeterminate{background-color:#3a72bd;border-color:#3a72bd;background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='M6 10h8'/%3e%3c/svg%3e")}.form-check-input:disabled{pointer-events:none;filter:none;opacity:.5}.form-check-input:disabled~.form-check-label,.form-check-input[disabled]~.form-check-label{opacity:.5}.form-switch{padding-left:2.5em}.form-switch .form-check-input{width:2em;margin-left:-2.5em;background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='rgba%280, 0, 0, 0.25%29'/%3e%3c/svg%3e");background-position:left center;border-radius:2em;transition:background-position .15s ease-in-out}@media (prefers-reduced-motion:reduce){.form-switch .form-check-input{transition:none}}.form-switch .form-check-input:focus{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%239db9de'/%3e%3c/svg%3e")}.form-switch .form-check-input:checked{background-position:right center;background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e")}.form-check-inline{display:inline-block;margin-right:1rem}.btn-check{position:absolute;clip:rect(0,0,0,0);pointer-events:none}.btn-check:disabled+.btn,.btn-check[disabled]+.btn{pointer-events:none;filter:none;opacity:.65}.form-range{width:100%;height:1.5rem;padding:0;background-color:transparent;-webkit-appearance:none;-moz-appearance:none;appearance:none}.form-range:focus{outline:0}.form-range:focus::-webkit-slider-thumb{box-shadow:0 0 0 1px #fff,0 0 0 .25rem rgba(58,114,189,.25)}.form-range:focus::-moz-range-thumb{box-shadow:0 0 0 1px #fff,0 0 0 .25rem rgba(58,114,189,.25)}.form-range::-moz-focus-outer{border:0}.form-range::-webkit-slider-thumb{width:1rem;height:1rem;margin-top:-.25rem;background-color:#3a72bd;border:0;border-radius:1rem;-webkit-transition:background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;transition:background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;-webkit-appearance:none;appearance:none}@media (prefers-reduced-motion:reduce){.form-range::-webkit-slider-thumb{-webkit-transition:none;transition:none}}.form-range::-webkit-slider-thumb:active{background-color:#c4d5eb}.form-range::-webkit-slider-runnable-track{width:100%;height:.5rem;color:transparent;cursor:pointer;background-color:#dee2e6;border-color:transparent;border-radius:1rem}.form-range::-moz-range-thumb{width:1rem;height:1rem;background-color:#3a72bd;border:0;border-radius:1rem;-moz-transition:background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;transition:background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;-moz-appearance:none;appearance:none}@media (prefers-reduced-motion:reduce){.form-range::-moz-range-thumb{-moz-transition:none;transition:none}}.form-range::-moz-range-thumb:active{background-color:#c4d5eb}.form-range::-moz-range-track{width:100%;height:.5rem;color:transparent;cursor:pointer;background-color:#dee2e6;border-color:transparent;border-radius:1rem}.form-range:disabled{pointer-events:none}.form-range:disabled::-webkit-slider-thumb{background-color:#adb5bd}.form-range:disabled::-moz-range-thumb{background-color:#adb5bd}.form-floating{position:relative}.form-floating>.form-control,.form-floating>.form-select{height:calc(3.5rem + 2px);line-height:1.25}.form-floating>label{position:absolute;top:0;left:0;height:100%;padding:1rem .75rem;pointer-events:none;border:1px solid transparent;transform-origin:0 0;transition:opacity .1s ease-in-out,transform .1s ease-in-out}@media (prefers-reduced-motion:reduce){.form-floating>label{transition:none}}.form-floating>.form-control{padding:1rem .75rem}.form-floating>.form-control::-moz-placeholder{color:transparent}.form-floating>.form-control::placeholder{color:transparent}.form-floating>.form-control:not(:-moz-placeholder-shown){padding-top:1.625rem;padding-bottom:.625rem}.form-floating>.form-control:focus,.form-floating>.form-control:not(:placeholder-shown){padding-top:1.625rem;padding-bottom:.625rem}.form-floating>.form-control:-webkit-autofill{padding-top:1.625rem;padding-bottom:.625rem}.form-floating>.form-select{padding-top:1.625rem;padding-bottom:.625rem}.form-floating>.form-control:not(:-moz-placeholder-shown)~label{opacity:.65;transform:scale(.85) translateY(-.5rem) translateX(.15rem)}.form-floating>.form-control:focus~label,.form-floating>.form-control:not(:placeholder-shown)~label,.form-floating>.form-select~label{opacity:.65;transform:scale(.85) translateY(-.5rem) translateX(.15rem)}.form-floating>.form-control:-webkit-autofill~label{opacity:.65;transform:scale(.85) translateY(-.5rem) translateX(.15rem)}.input-group{position:relative;display:flex;flex-wrap:wrap;align-items:stretch;width:100%}.input-group>.form-control,.input-group>.form-select{position:relative;flex:1 1 auto;width:1%;min-width:0}.input-group>.form-control:focus,.input-group>.form-select:focus{z-index:3}.input-group .btn{position:relative;z-index:2}.input-group .btn:focus{z-index:3}.input-group-text{display:flex;align-items:center;padding:.375rem .75rem;font-size:1rem;font-weight:400;line-height:1.5;color:#212529;text-align:center;white-space:nowrap;background-color:#e9ecef;border:1px solid #ced4da;border-radius:.25rem}.input-group-lg>.btn,.input-group-lg>.form-control,.input-group-lg>.form-select,.input-group-lg>.input-group-text{padding:.5rem 1rem;font-size:1.25rem;border-radius:.3rem}.input-group-sm>.btn,.input-group-sm>.form-control,.input-group-sm>.form-select,.input-group-sm>.input-group-text{padding:.25rem .5rem;font-size:.875rem;border-radius:.2rem}.input-group-lg>.form-select,.input-group-sm>.form-select{padding-right:3rem}.input-group:not(.has-validation)>.dropdown-toggle:nth-last-child(n+3),.input-group:not(.has-validation)>:not(:last-child):not(.dropdown-toggle):not(.dropdown-menu){border-top-right-radius:0;border-bottom-right-radius:0}.input-group.has-validation>.dropdown-toggle:nth-last-child(n+4),.input-group.has-validation>:nth-last-child(n+3):not(.dropdown-toggle):not(.dropdown-menu){border-top-right-radius:0;border-bottom-right-radius:0}.input-group>:not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback){margin-left:-1px;border-top-left-radius:0;border-bottom-left-radius:0}.valid-feedback{display:none;width:100%;margin-top:.25rem;font-size:.875em;color:#30aa5b}.valid-tooltip{position:absolute;top:100%;z-index:5;display:none;max-width:100%;padding:.25rem .5rem;margin-top:.1rem;font-size:.875rem;color:#fff;background-color:rgba(48,170,91,.9);border-radius:.25rem}.is-valid~.valid-feedback,.is-valid~.valid-tooltip,.was-validated :valid~.valid-feedback,.was-validated :valid~.valid-tooltip{display:block}.form-control.is-valid,.was-validated .form-control:valid{border-color:#30aa5b;padding-right:calc(1.5em + .75rem);background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%2330aa5b' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e");background-repeat:no-repeat;background-position:right calc(.375em + .1875rem) center;background-size:calc(.75em + .375rem) calc(.75em + .375rem)}.form-control.is-valid:focus,.was-validated .form-control:valid:focus{border-color:#30aa5b;box-shadow:0 0 0 .25rem rgba(48,170,91,.25)}.was-validated textarea.form-control:valid,textarea.form-control.is-valid{padding-right:calc(1.5em + .75rem);background-position:top calc(.375em + .1875rem) right calc(.375em + .1875rem)}.form-select.is-valid,.was-validated .form-select:valid{border-color:#30aa5b}.form-select.is-valid:not([multiple]):not([size]),.form-select.is-valid:not([multiple])[size="1"],.was-validated .form-select:valid:not([multiple]):not([size]),.was-validated .form-select:valid:not([multiple])[size="1"]{padding-right:4.125rem;background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e"),url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%2330aa5b' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e");background-position:right .75rem center,center right 2.25rem;background-size:16px 12px,calc(.75em + .375rem) calc(.75em + .375rem)}.form-select.is-valid:focus,.was-validated .form-select:valid:focus{border-color:#30aa5b;box-shadow:0 0 0 .25rem rgba(48,170,91,.25)}.form-check-input.is-valid,.was-validated .form-check-input:valid{border-color:#30aa5b}.form-check-input.is-valid:checked,.was-validated .form-check-input:valid:checked{background-color:#30aa5b}.form-check-input.is-valid:focus,.was-validated .form-check-input:valid:focus{box-shadow:0 0 0 .25rem rgba(48,170,91,.25)}.form-check-input.is-valid~.form-check-label,.was-validated .form-check-input:valid~.form-check-label{color:#30aa5b}.form-check-inline .form-check-input~.valid-feedback{margin-left:.5em}.input-group .form-control.is-valid,.input-group .form-select.is-valid,.was-validated .input-group .form-control:valid,.was-validated .input-group .form-select:valid{z-index:1}.input-group .form-control.is-valid:focus,.input-group .form-select.is-valid:focus,.was-validated .input-group .form-control:valid:focus,.was-validated .input-group .form-select:valid:focus{z-index:3}.invalid-feedback{display:none;width:100%;margin-top:.25rem;font-size:.875em;color:#dc3545}.invalid-tooltip{position:absolute;top:100%;z-index:5;display:none;max-width:100%;padding:.25rem .5rem;margin-top:.1rem;font-size:.875rem;color:#fff;background-color:rgba(220,53,69,.9);border-radius:.25rem}.is-invalid~.invalid-feedback,.is-invalid~.invalid-tooltip,.was-validated :invalid~.invalid-feedback,.was-validated :invalid~.invalid-tooltip{display:block}.form-control.is-invalid,.was-validated .form-control:invalid{border-color:#dc3545;padding-right:calc(1.5em + .75rem);background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");background-repeat:no-repeat;background-position:right calc(.375em + .1875rem) center;background-size:calc(.75em + .375rem) calc(.75em + .375rem)}.form-control.is-invalid:focus,.was-validated .form-control:invalid:focus{border-color:#dc3545;box-shadow:0 0 0 .25rem rgba(220,53,69,.25)}.was-validated textarea.form-control:invalid,textarea.form-control.is-invalid{padding-right:calc(1.5em + .75rem);background-position:top calc(.375em + .1875rem) right calc(.375em + .1875rem)}.form-select.is-invalid,.was-validated .form-select:invalid{border-color:#dc3545}.form-select.is-invalid:not([multiple]):not([size]),.form-select.is-invalid:not([multiple])[size="1"],.was-validated .form-select:invalid:not([multiple]):not([size]),.was-validated .form-select:invalid:not([multiple])[size="1"]{padding-right:4.125rem;background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e"),url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");background-position:right .75rem center,center right 2.25rem;background-size:16px 12px,calc(.75em + .375rem) calc(.75em + .375rem)}.form-select.is-invalid:focus,.was-validated .form-select:invalid:focus{border-color:#dc3545;box-shadow:0 0 0 .25rem rgba(220,53,69,.25)}.form-check-input.is-invalid,.was-validated .form-check-input:invalid{border-color:#dc3545}.form-check-input.is-invalid:checked,.was-validated .form-check-input:invalid:checked{background-color:#dc3545}.form-check-input.is-invalid:focus,.was-validated .form-check-input:invalid:focus{box-shadow:0 0 0 .25rem rgba(220,53,69,.25)}.form-check-input.is-invalid~.form-check-label,.was-validated .form-check-input:invalid~.form-check-label{color:#dc3545}.form-check-inline .form-check-input~.invalid-feedback{margin-left:.5em}.input-group .form-control.is-invalid,.input-group .form-select.is-invalid,.was-validated .input-group .form-control:invalid,.was-validated .input-group .form-select:invalid{z-index:2}.input-group .form-control.is-invalid:focus,.input-group .form-select.is-invalid:focus,.was-validated .input-group .form-control:invalid:focus,.was-validated .input-group .form-select:invalid:focus{z-index:3}.btn{display:inline-block;font-weight:400;line-height:1.5;color:#212529;text-align:center;text-decoration:none;vertical-align:middle;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;user-select:none;background-color:transparent;border:1px solid transparent;padding:.375rem .75rem;font-size:1rem;border-radius:.25rem;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}@media (prefers-reduced-motion:reduce){.btn{transition:none}}.btn:hover{color:#212529}.btn-check:focus+.btn,.btn:focus{outline:0;box-shadow:0 0 0 .25rem rgba(58,114,189,.25)}.btn.disabled,.btn:disabled,fieldset:disabled .btn{pointer-events:none;opacity:.65}.btn-primary{color:#fff;background-color:#3a72bd;border-color:#3a72bd}.btn-primary:hover{color:#fff;background-color:#3161a1;border-color:#2e5b97}.btn-check:focus+.btn-primary,.btn-primary:focus{color:#fff;background-color:#3161a1;border-color:#2e5b97;box-shadow:0 0 0 .25rem rgba(88,135,199,.5)}.btn-check:active+.btn-primary,.btn-check:checked+.btn-primary,.btn-primary.active,.btn-primary:active,.show>.btn-primary.dropdown-toggle{color:#fff;background-color:#2e5b97;border-color:#2c568e}.btn-check:active+.btn-primary:focus,.btn-check:checked+.btn-primary:focus,.btn-primary.active:focus,.btn-primary:active:focus,.show>.btn-primary.dropdown-toggle:focus{box-shadow:0 0 0 .25rem rgba(88,135,199,.5)}.btn-primary.disabled,.btn-primary:disabled{color:#fff;background-color:#3a72bd;border-color:#3a72bd}.btn-secondary{color:#fff;background-color:#6c757d;border-color:#6c757d}.btn-secondary:hover{color:#fff;background-color:#5c636a;border-color:#565e64}.btn-check:focus+.btn-secondary,.btn-secondary:focus{color:#fff;background-color:#5c636a;border-color:#565e64;box-shadow:0 0 0 .25rem rgba(130,138,145,.5)}.btn-check:active+.btn-secondary,.btn-check:checked+.btn-secondary,.btn-secondary.active,.btn-secondary:active,.show>.btn-secondary.dropdown-toggle{color:#fff;background-color:#565e64;border-color:#51585e}.btn-check:active+.btn-secondary:focus,.btn-check:checked+.btn-secondary:focus,.btn-secondary.active:focus,.btn-secondary:active:focus,.show>.btn-secondary.dropdown-toggle:focus{box-shadow:0 0 0 .25rem rgba(130,138,145,.5)}.btn-secondary.disabled,.btn-secondary:disabled{color:#fff;background-color:#6c757d;border-color:#6c757d}.btn-success{color:#fff;background-color:#30aa5b;border-color:#30aa5b}.btn-success:hover{color:#fff;background-color:#29914d;border-color:#268849}.btn-check:focus+.btn-success,.btn-success:focus{color:#fff;background-color:#29914d;border-color:#268849;box-shadow:0 0 0 .25rem rgba(79,183,116,.5)}.btn-check:active+.btn-success,.btn-check:checked+.btn-success,.btn-success.active,.btn-success:active,.show>.btn-success.dropdown-toggle{color:#fff;background-color:#268849;border-color:#248044}.btn-check:active+.btn-success:focus,.btn-check:checked+.btn-success:focus,.btn-success.active:focus,.btn-success:active:focus,.show>.btn-success.dropdown-toggle:focus{box-shadow:0 0 0 .25rem rgba(79,183,116,.5)}.btn-success.disabled,.btn-success:disabled{color:#fff;background-color:#30aa5b;border-color:#30aa5b}.btn-info{color:#fff;background-color:#17a2b8;border-color:#17a2b8}.btn-info:hover{color:#fff;background-color:#148a9c;border-color:#128293}.btn-check:focus+.btn-info,.btn-info:focus{color:#fff;background-color:#148a9c;border-color:#128293;box-shadow:0 0 0 .25rem rgba(58,176,195,.5)}.btn-check:active+.btn-info,.btn-check:checked+.btn-info,.btn-info.active,.btn-info:active,.show>.btn-info.dropdown-toggle{color:#fff;background-color:#128293;border-color:#117a8a}.btn-check:active+.btn-info:focus,.btn-check:checked+.btn-info:focus,.btn-info.active:focus,.btn-info:active:focus,.show>.btn-info.dropdown-toggle:focus{box-shadow:0 0 0 .25rem rgba(58,176,195,.5)}.btn-info.disabled,.btn-info:disabled{color:#fff;background-color:#17a2b8;border-color:#17a2b8}.btn-warning{color:#fff;background-color:#edaa16;border-color:#edaa16}.btn-warning:hover{color:#fff;background-color:#c99113;border-color:#be8812}.btn-check:focus+.btn-warning,.btn-warning:focus{color:#fff;background-color:#c99113;border-color:#be8812;box-shadow:0 0 0 .25rem rgba(240,183,57,.5)}.btn-check:active+.btn-warning,.btn-check:checked+.btn-warning,.btn-warning.active,.btn-warning:active,.show>.btn-warning.dropdown-toggle{color:#fff;background-color:#be8812;border-color:#b28011}.btn-check:active+.btn-warning:focus,.btn-check:checked+.btn-warning:focus,.btn-warning.active:focus,.btn-warning:active:focus,.show>.btn-warning.dropdown-toggle:focus{box-shadow:0 0 0 .25rem rgba(240,183,57,.5)}.btn-warning.disabled,.btn-warning:disabled{color:#fff;background-color:#edaa16;border-color:#edaa16}.btn-danger{color:#fff;background-color:#dc3545;border-color:#dc3545}.btn-danger:hover{color:#fff;background-color:#bb2d3b;border-color:#b02a37}.btn-check:focus+.btn-danger,.btn-danger:focus{color:#fff;background-color:#bb2d3b;border-color:#b02a37;box-shadow:0 0 0 .25rem rgba(225,83,97,.5)}.btn-check:active+.btn-danger,.btn-check:checked+.btn-danger,.btn-danger.active,.btn-danger:active,.show>.btn-danger.dropdown-toggle{color:#fff;background-color:#b02a37;border-color:#a52834}.btn-check:active+.btn-danger:focus,.btn-check:checked+.btn-danger:focus,.btn-danger.active:focus,.btn-danger:active:focus,.show>.btn-danger.dropdown-toggle:focus{box-shadow:0 0 0 .25rem rgba(225,83,97,.5)}.btn-danger.disabled,.btn-danger:disabled{color:#fff;background-color:#dc3545;border-color:#dc3545}.btn-light{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}.btn-light:hover{color:#000;background-color:#f9fafb;border-color:#f9fafb}.btn-check:focus+.btn-light,.btn-light:focus{color:#000;background-color:#f9fafb;border-color:#f9fafb;box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}.btn-check:active+.btn-light,.btn-check:checked+.btn-light,.btn-light.active,.btn-light:active,.show>.btn-light.dropdown-toggle{color:#000;background-color:#f9fafb;border-color:#f9fafb}.btn-check:active+.btn-light:focus,.btn-check:checked+.btn-light:focus,.btn-light.active:focus,.btn-light:active:focus,.show>.btn-light.dropdown-toggle:focus{box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}.btn-light.disabled,.btn-light:disabled{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}.btn-dark{color:#fff;background-color:#212529;border-color:#212529}.btn-dark:hover{color:#fff;background-color:#1c1f23;border-color:#1a1e21}.btn-check:focus+.btn-dark,.btn-dark:focus{color:#fff;background-color:#1c1f23;border-color:#1a1e21;box-shadow:0 0 0 .25rem rgba(66,70,73,.5)}.btn-check:active+.btn-dark,.btn-check:checked+.btn-dark,.btn-dark.active,.btn-dark:active,.show>.btn-dark.dropdown-toggle{color:#fff;background-color:#1a1e21;border-color:#191c1f}.btn-check:active+.btn-dark:focus,.btn-check:checked+.btn-dark:focus,.btn-dark.active:focus,.btn-dark:active:focus,.show>.btn-dark.dropdown-toggle:focus{box-shadow:0 0 0 .25rem rgba(66,70,73,.5)}.btn-dark.disabled,.btn-dark:disabled{color:#fff;background-color:#212529;border-color:#212529}.btn-outline-primary{color:#3a72bd;border-color:#3a72bd}.btn-outline-primary:hover{color:#fff;background-color:#3a72bd;border-color:#3a72bd}.btn-check:focus+.btn-outline-primary,.btn-outline-primary:focus{box-shadow:0 0 0 .25rem rgba(58,114,189,.5)}.btn-check:active+.btn-outline-primary,.btn-check:checked+.btn-outline-primary,.btn-outline-primary.active,.btn-outline-primary.dropdown-toggle.show,.btn-outline-primary:active{color:#fff;background-color:#3a72bd;border-color:#3a72bd}.btn-check:active+.btn-outline-primary:focus,.btn-check:checked+.btn-outline-primary:focus,.btn-outline-primary.active:focus,.btn-outline-primary.dropdown-toggle.show:focus,.btn-outline-primary:active:focus{box-shadow:0 0 0 .25rem rgba(58,114,189,.5)}.btn-outline-primary.disabled,.btn-outline-primary:disabled{color:#3a72bd;background-color:transparent}.btn-outline-secondary{color:#6c757d;border-color:#6c757d}.btn-outline-secondary:hover{color:#fff;background-color:#6c757d;border-color:#6c757d}.btn-check:focus+.btn-outline-secondary,.btn-outline-secondary:focus{box-shadow:0 0 0 .25rem rgba(108,117,125,.5)}.btn-check:active+.btn-outline-secondary,.btn-check:checked+.btn-outline-secondary,.btn-outline-secondary.active,.btn-outline-secondary.dropdown-toggle.show,.btn-outline-secondary:active{color:#fff;background-color:#6c757d;border-color:#6c757d}.btn-check:active+.btn-outline-secondary:focus,.btn-check:checked+.btn-outline-secondary:focus,.btn-outline-secondary.active:focus,.btn-outline-secondary.dropdown-toggle.show:focus,.btn-outline-secondary:active:focus{box-shadow:0 0 0 .25rem rgba(108,117,125,.5)}.btn-outline-secondary.disabled,.btn-outline-secondary:disabled{color:#6c757d;background-color:transparent}.btn-outline-success{color:#30aa5b;border-color:#30aa5b}.btn-outline-success:hover{color:#fff;background-color:#30aa5b;border-color:#30aa5b}.btn-check:focus+.btn-outline-success,.btn-outline-success:focus{box-shadow:0 0 0 .25rem rgba(48,170,91,.5)}.btn-check:active+.btn-outline-success,.btn-check:checked+.btn-outline-success,.btn-outline-success.active,.btn-outline-success.dropdown-toggle.show,.btn-outline-success:active{color:#fff;background-color:#30aa5b;border-color:#30aa5b}.btn-check:active+.btn-outline-success:focus,.btn-check:checked+.btn-outline-success:focus,.btn-outline-success.active:focus,.btn-outline-success.dropdown-toggle.show:focus,.btn-outline-success:active:focus{box-shadow:0 0 0 .25rem rgba(48,170,91,.5)}.btn-outline-success.disabled,.btn-outline-success:disabled{color:#30aa5b;background-color:transparent}.btn-outline-info{color:#17a2b8;border-color:#17a2b8}.btn-outline-info:hover{color:#fff;background-color:#17a2b8;border-color:#17a2b8}.btn-check:focus+.btn-outline-info,.btn-outline-info:focus{box-shadow:0 0 0 .25rem rgba(23,162,184,.5)}.btn-check:active+.btn-outline-info,.btn-check:checked+.btn-outline-info,.btn-outline-info.active,.btn-outline-info.dropdown-toggle.show,.btn-outline-info:active{color:#fff;background-color:#17a2b8;border-color:#17a2b8}.btn-check:active+.btn-outline-info:focus,.btn-check:checked+.btn-outline-info:focus,.btn-outline-info.active:focus,.btn-outline-info.dropdown-toggle.show:focus,.btn-outline-info:active:focus{box-shadow:0 0 0 .25rem rgba(23,162,184,.5)}.btn-outline-info.disabled,.btn-outline-info:disabled{color:#17a2b8;background-color:transparent}.btn-outline-warning{color:#edaa16;border-color:#edaa16}.btn-outline-warning:hover{color:#fff;background-color:#edaa16;border-color:#edaa16}.btn-check:focus+.btn-outline-warning,.btn-outline-warning:focus{box-shadow:0 0 0 .25rem rgba(237,170,22,.5)}.btn-check:active+.btn-outline-warning,.btn-check:checked+.btn-outline-warning,.btn-outline-warning.active,.btn-outline-warning.dropdown-toggle.show,.btn-outline-warning:active{color:#fff;background-color:#edaa16;border-color:#edaa16}.btn-check:active+.btn-outline-warning:focus,.btn-check:checked+.btn-outline-warning:focus,.btn-outline-warning.active:focus,.btn-outline-warning.dropdown-toggle.show:focus,.btn-outline-warning:active:focus{box-shadow:0 0 0 .25rem rgba(237,170,22,.5)}.btn-outline-warning.disabled,.btn-outline-warning:disabled{color:#edaa16;background-color:transparent}.btn-outline-danger{color:#dc3545;border-color:#dc3545}.btn-outline-danger:hover{color:#fff;background-color:#dc3545;border-color:#dc3545}.btn-check:focus+.btn-outline-danger,.btn-outline-danger:focus{box-shadow:0 0 0 .25rem rgba(220,53,69,.5)}.btn-check:active+.btn-outline-danger,.btn-check:checked+.btn-outline-danger,.btn-outline-danger.active,.btn-outline-danger.dropdown-toggle.show,.btn-outline-danger:active{color:#fff;background-color:#dc3545;border-color:#dc3545}.btn-check:active+.btn-outline-danger:focus,.btn-check:checked+.btn-outline-danger:focus,.btn-outline-danger.active:focus,.btn-outline-danger.dropdown-toggle.show:focus,.btn-outline-danger:active:focus{box-shadow:0 0 0 .25rem rgba(220,53,69,.5)}.btn-outline-danger.disabled,.btn-outline-danger:disabled{color:#dc3545;background-color:transparent}.btn-outline-light{color:#f8f9fa;border-color:#f8f9fa}.btn-outline-light:hover{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}.btn-check:focus+.btn-outline-light,.btn-outline-light:focus{box-shadow:0 0 0 .25rem rgba(248,249,250,.5)}.btn-check:active+.btn-outline-light,.btn-check:checked+.btn-outline-light,.btn-outline-light.active,.btn-outline-light.dropdown-toggle.show,.btn-outline-light:active{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}.btn-check:active+.btn-outline-light:focus,.btn-check:checked+.btn-outline-light:focus,.btn-outline-light.active:focus,.btn-outline-light.dropdown-toggle.show:focus,.btn-outline-light:active:focus{box-shadow:0 0 0 .25rem rgba(248,249,250,.5)}.btn-outline-light.disabled,.btn-outline-light:disabled{color:#f8f9fa;background-color:transparent}.btn-outline-dark{color:#212529;border-color:#212529}.btn-outline-dark:hover{color:#fff;background-color:#212529;border-color:#212529}.btn-check:focus+.btn-outline-dark,.btn-outline-dark:focus{box-shadow:0 0 0 .25rem rgba(33,37,41,.5)}.btn-check:active+.btn-outline-dark,.btn-check:checked+.btn-outline-dark,.btn-outline-dark.active,.btn-outline-dark.dropdown-toggle.show,.btn-outline-dark:active{color:#fff;background-color:#212529;border-color:#212529}.btn-check:active+.btn-outline-dark:focus,.btn-check:checked+.btn-outline-dark:focus,.btn-outline-dark.active:focus,.btn-outline-dark.dropdown-toggle.show:focus,.btn-outline-dark:active:focus{box-shadow:0 0 0 .25rem rgba(33,37,41,.5)}.btn-outline-dark.disabled,.btn-outline-dark:disabled{color:#212529;background-color:transparent}.btn-link{font-weight:400;color:#3a72bd;text-decoration:underline}.btn-link:hover{color:#2e5b97}.btn-link.disabled,.btn-link:disabled{color:#6c757d}.btn-group-lg>.btn,.btn-lg{padding:.5rem 1rem;font-size:1.25rem;border-radius:.3rem}.btn-group-sm>.btn,.btn-sm{padding:.25rem .5rem;font-size:.875rem;border-radius:.2rem}.fade{transition:opacity .15s linear}@media (prefers-reduced-motion:reduce){.fade{transition:none}}.fade:not(.show){opacity:0}.collapse:not(.show){display:none}.collapsing{height:0;overflow:hidden;transition:height .35s ease}@media (prefers-reduced-motion:reduce){.collapsing{transition:none}}.collapsing.collapse-horizontal{width:0;height:auto;transition:width .35s ease}@media (prefers-reduced-motion:reduce){.collapsing.collapse-horizontal{transition:none}}.dropdown,.dropend,.dropstart,.dropup{position:relative}.dropdown-toggle{white-space:nowrap}.dropdown-toggle::after{display:inline-block;margin-left:.255em;vertical-align:.255em;content:"";border-top:.3em solid;border-right:.3em solid transparent;border-bottom:0;border-left:.3em solid transparent}.dropdown-toggle:empty::after{margin-left:0}.dropdown-menu{position:absolute;z-index:1000;display:none;min-width:10rem;padding:.5rem 0;margin:0;font-size:1rem;color:#212529;text-align:left;list-style:none;background-color:#fff;background-clip:padding-box;border:1px solid rgba(0,0,0,.15);border-radius:.25rem}.dropdown-menu[data-bs-popper]{top:100%;left:0;margin-top:.125rem}.dropdown-menu-start{--bs-position:start}.dropdown-menu-start[data-bs-popper]{right:auto;left:0}.dropdown-menu-end{--bs-position:end}.dropdown-menu-end[data-bs-popper]{right:0;left:auto}@media (min-width:576px){.dropdown-menu-sm-start{--bs-position:start}.dropdown-menu-sm-start[data-bs-popper]{right:auto;left:0}.dropdown-menu-sm-end{--bs-position:end}.dropdown-menu-sm-end[data-bs-popper]{right:0;left:auto}}@media (min-width:768px){.dropdown-menu-md-start{--bs-position:start}.dropdown-menu-md-start[data-bs-popper]{right:auto;left:0}.dropdown-menu-md-end{--bs-position:end}.dropdown-menu-md-end[data-bs-popper]{right:0;left:auto}}@media (min-width:992px){.dropdown-menu-lg-start{--bs-position:start}.dropdown-menu-lg-start[data-bs-popper]{right:auto;left:0}.dropdown-menu-lg-end{--bs-position:end}.dropdown-menu-lg-end[data-bs-popper]{right:0;left:auto}}@media (min-width:1200px){.dropdown-menu-xl-start{--bs-position:start}.dropdown-menu-xl-start[data-bs-popper]{right:auto;left:0}.dropdown-menu-xl-end{--bs-position:end}.dropdown-menu-xl-end[data-bs-popper]{right:0;left:auto}}@media (min-width:1400px){.dropdown-menu-xxl-start{--bs-position:start}.dropdown-menu-xxl-start[data-bs-popper]{right:auto;left:0}.dropdown-menu-xxl-end{--bs-position:end}.dropdown-menu-xxl-end[data-bs-popper]{right:0;left:auto}}.dropup .dropdown-menu[data-bs-popper]{top:auto;bottom:100%;margin-top:0;margin-bottom:.125rem}.dropup .dropdown-toggle::after{display:inline-block;margin-left:.255em;vertical-align:.255em;content:"";border-top:0;border-right:.3em solid transparent;border-bottom:.3em solid;border-left:.3em solid transparent}.dropup .dropdown-toggle:empty::after{margin-left:0}.dropend .dropdown-menu[data-bs-popper]{top:0;right:auto;left:100%;margin-top:0;margin-left:.125rem}.dropend .dropdown-toggle::after{display:inline-block;margin-left:.255em;vertical-align:.255em;content:"";border-top:.3em solid transparent;border-right:0;border-bottom:.3em solid transparent;border-left:.3em solid}.dropend .dropdown-toggle:empty::after{margin-left:0}.dropend .dropdown-toggle::after{vertical-align:0}.dropstart .dropdown-menu[data-bs-popper]{top:0;right:100%;left:auto;margin-top:0;margin-right:.125rem}.dropstart .dropdown-toggle::after{display:inline-block;margin-left:.255em;vertical-align:.255em;content:""}.dropstart .dropdown-toggle::after{display:none}.dropstart .dropdown-toggle::before{display:inline-block;margin-right:.255em;vertical-align:.255em;content:"";border-top:.3em solid transparent;border-right:.3em solid;border-bottom:.3em solid transparent}.dropstart .dropdown-toggle:empty::after{margin-left:0}.dropstart .dropdown-toggle::before{vertical-align:0}.dropdown-divider{height:0;margin:.5rem 0;overflow:hidden;border-top:1px solid rgba(0,0,0,.15)}.dropdown-item{display:block;width:100%;padding:.25rem 1rem;clear:both;font-weight:400;color:#212529;text-align:inherit;text-decoration:none;white-space:nowrap;background-color:transparent;border:0}.dropdown-item:focus,.dropdown-item:hover{color:#1e2125;background-color:#e9ecef}.dropdown-item.active,.dropdown-item:active{color:#fff;text-decoration:none;background-color:#3a72bd}.dropdown-item.disabled,.dropdown-item:disabled{color:#adb5bd;pointer-events:none;background-color:transparent}.dropdown-menu.show{display:block}.dropdown-header{display:block;padding:.5rem 1rem;margin-bottom:0;font-size:.875rem;color:#6c757d;white-space:nowrap}.dropdown-item-text{display:block;padding:.25rem 1rem;color:#212529}.dropdown-menu-dark{color:#dee2e6;background-color:#343a40;border-color:rgba(0,0,0,.15)}.dropdown-menu-dark .dropdown-item{color:#dee2e6}.dropdown-menu-dark .dropdown-item:focus,.dropdown-menu-dark .dropdown-item:hover{color:#fff;background-color:rgba(255,255,255,.15)}.dropdown-menu-dark .dropdown-item.active,.dropdown-menu-dark .dropdown-item:active{color:#fff;background-color:#3a72bd}.dropdown-menu-dark .dropdown-item.disabled,.dropdown-menu-dark .dropdown-item:disabled{color:#adb5bd}.dropdown-menu-dark .dropdown-divider{border-color:rgba(0,0,0,.15)}.dropdown-menu-dark .dropdown-item-text{color:#dee2e6}.dropdown-menu-dark .dropdown-header{color:#adb5bd}.btn-group,.btn-group-vertical{position:relative;display:inline-flex;vertical-align:middle}.btn-group-vertical>.btn,.btn-group>.btn{position:relative;flex:1 1 auto}.btn-group-vertical>.btn-check:checked+.btn,.btn-group-vertical>.btn-check:focus+.btn,.btn-group-vertical>.btn.active,.btn-group-vertical>.btn:active,.btn-group-vertical>.btn:focus,.btn-group-vertical>.btn:hover,.btn-group>.btn-check:checked+.btn,.btn-group>.btn-check:focus+.btn,.btn-group>.btn.active,.btn-group>.btn:active,.btn-group>.btn:focus,.btn-group>.btn:hover{z-index:1}.btn-toolbar{display:flex;flex-wrap:wrap;justify-content:flex-start}.btn-toolbar .input-group{width:auto}.btn-group>.btn-group:not(:first-child),.btn-group>.btn:not(:first-child){margin-left:-1px}.btn-group>.btn-group:not(:last-child)>.btn,.btn-group>.btn:not(:last-child):not(.dropdown-toggle){border-top-right-radius:0;border-bottom-right-radius:0}.btn-group>.btn-group:not(:first-child)>.btn,.btn-group>.btn:nth-child(n+3),.btn-group>:not(.btn-check)+.btn{border-top-left-radius:0;border-bottom-left-radius:0}.dropdown-toggle-split{padding-right:.5625rem;padding-left:.5625rem}.dropdown-toggle-split::after,.dropend .dropdown-toggle-split::after,.dropup .dropdown-toggle-split::after{margin-left:0}.dropstart .dropdown-toggle-split::before{margin-right:0}.btn-group-sm>.btn+.dropdown-toggle-split,.btn-sm+.dropdown-toggle-split{padding-right:.375rem;padding-left:.375rem}.btn-group-lg>.btn+.dropdown-toggle-split,.btn-lg+.dropdown-toggle-split{padding-right:.75rem;padding-left:.75rem}.btn-group-vertical{flex-direction:column;align-items:flex-start;justify-content:center}.btn-group-vertical>.btn,.btn-group-vertical>.btn-group{width:100%}.btn-group-vertical>.btn-group:not(:first-child),.btn-group-vertical>.btn:not(:first-child){margin-top:-1px}.btn-group-vertical>.btn-group:not(:last-child)>.btn,.btn-group-vertical>.btn:not(:last-child):not(.dropdown-toggle){border-bottom-right-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn-group:not(:first-child)>.btn,.btn-group-vertical>.btn~.btn{border-top-left-radius:0;border-top-right-radius:0}.nav{display:flex;flex-wrap:wrap;padding-left:0;margin-bottom:0;list-style:none}.nav-link{display:block;padding:.5rem 1rem;color:#3a72bd;text-decoration:none;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out}@media (prefers-reduced-motion:reduce){.nav-link{transition:none}}.nav-link:focus,.nav-link:hover{color:#2e5b97}.nav-link.disabled{color:#6c757d;pointer-events:none;cursor:default}.nav-tabs{border-bottom:1px solid #dee2e6}.nav-tabs .nav-link{margin-bottom:-1px;background:0 0;border:1px solid transparent;border-top-left-radius:.25rem;border-top-right-radius:.25rem}.nav-tabs .nav-link:focus,.nav-tabs .nav-link:hover{border-color:#e9ecef #e9ecef #dee2e6;isolation:isolate}.nav-tabs .nav-link.disabled{color:#6c757d;background-color:transparent;border-color:transparent}.nav-tabs .nav-item.show .nav-link,.nav-tabs .nav-link.active{color:#495057;background-color:#fff;border-color:#dee2e6 #dee2e6 #fff}.nav-tabs .dropdown-menu{margin-top:-1px;border-top-left-radius:0;border-top-right-radius:0}.nav-pills .nav-link{background:0 0;border:0;border-radius:.25rem}.nav-pills .nav-link.active,.nav-pills .show>.nav-link{color:#fff;background-color:#3a72bd}.nav-fill .nav-item,.nav-fill>.nav-link{flex:1 1 auto;text-align:center}.nav-justified .nav-item,.nav-justified>.nav-link{flex-basis:0;flex-grow:1;text-align:center}.nav-fill .nav-item .nav-link,.nav-justified .nav-item .nav-link{width:100%}.tab-content>.tab-pane{display:none}.tab-content>.active{display:block}.navbar{position:relative;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;padding-top:.5rem;padding-bottom:.5rem}.navbar>.container,.navbar>.container-fluid,.navbar>.container-lg,.navbar>.container-md,.navbar>.container-sm,.navbar>.container-xl,.navbar>.container-xxl{display:flex;flex-wrap:inherit;align-items:center;justify-content:space-between}.navbar-brand{padding-top:.3125rem;padding-bottom:.3125rem;margin-right:1rem;font-size:1.25rem;text-decoration:none;white-space:nowrap}.navbar-nav{display:flex;flex-direction:column;padding-left:0;margin-bottom:0;list-style:none}.navbar-nav .nav-link{padding-right:0;padding-left:0}.navbar-nav .dropdown-menu{position:static}.navbar-text{padding-top:.5rem;padding-bottom:.5rem}.navbar-collapse{flex-basis:100%;flex-grow:1;align-items:center}.navbar-toggler{padding:.25rem .75rem;font-size:1.25rem;line-height:1;background-color:transparent;border:1px solid transparent;border-radius:.25rem;transition:box-shadow .15s ease-in-out}@media (prefers-reduced-motion:reduce){.navbar-toggler{transition:none}}.navbar-toggler:hover{text-decoration:none}.navbar-toggler:focus{text-decoration:none;outline:0;box-shadow:0 0 0 .25rem}.navbar-toggler-icon{display:inline-block;width:1.5em;height:1.5em;vertical-align:middle;background-repeat:no-repeat;background-position:center;background-size:100%}.navbar-nav-scroll{max-height:var(--bs-scroll-height,75vh);overflow-y:auto}@media (min-width:576px){.navbar-expand-sm{flex-wrap:nowrap;justify-content:flex-start}.navbar-expand-sm .navbar-nav{flex-direction:row}.navbar-expand-sm .navbar-nav .dropdown-menu{position:absolute}.navbar-expand-sm .navbar-nav .nav-link{padding-right:.5rem;padding-left:.5rem}.navbar-expand-sm .navbar-nav-scroll{overflow:visible}.navbar-expand-sm .navbar-collapse{display:flex!important;flex-basis:auto}.navbar-expand-sm .navbar-toggler{display:none}.navbar-expand-sm .offcanvas-header{display:none}.navbar-expand-sm .offcanvas{position:inherit;bottom:0;z-index:1000;flex-grow:1;visibility:visible!important;background-color:transparent;border-right:0;border-left:0;transition:none;transform:none}.navbar-expand-sm .offcanvas-bottom,.navbar-expand-sm .offcanvas-top{height:auto;border-top:0;border-bottom:0}.navbar-expand-sm .offcanvas-body{display:flex;flex-grow:0;padding:0;overflow-y:visible}}@media (min-width:768px){.navbar-expand-md{flex-wrap:nowrap;justify-content:flex-start}.navbar-expand-md .navbar-nav{flex-direction:row}.navbar-expand-md .navbar-nav .dropdown-menu{position:absolute}.navbar-expand-md .navbar-nav .nav-link{padding-right:.5rem;padding-left:.5rem}.navbar-expand-md .navbar-nav-scroll{overflow:visible}.navbar-expand-md .navbar-collapse{display:flex!important;flex-basis:auto}.navbar-expand-md .navbar-toggler{display:none}.navbar-expand-md .offcanvas-header{display:none}.navbar-expand-md .offcanvas{position:inherit;bottom:0;z-index:1000;flex-grow:1;visibility:visible!important;background-color:transparent;border-right:0;border-left:0;transition:none;transform:none}.navbar-expand-md .offcanvas-bottom,.navbar-expand-md .offcanvas-top{height:auto;border-top:0;border-bottom:0}.navbar-expand-md .offcanvas-body{display:flex;flex-grow:0;padding:0;overflow-y:visible}}@media (min-width:992px){.navbar-expand-lg{flex-wrap:nowrap;justify-content:flex-start}.navbar-expand-lg .navbar-nav{flex-direction:row}.navbar-expand-lg .navbar-nav .dropdown-menu{position:absolute}.navbar-expand-lg .navbar-nav .nav-link{padding-right:.5rem;padding-left:.5rem}.navbar-expand-lg .navbar-nav-scroll{overflow:visible}.navbar-expand-lg .navbar-collapse{display:flex!important;flex-basis:auto}.navbar-expand-lg .navbar-toggler{display:none}.navbar-expand-lg .offcanvas-header{display:none}.navbar-expand-lg .offcanvas{position:inherit;bottom:0;z-index:1000;flex-grow:1;visibility:visible!important;background-color:transparent;border-right:0;border-left:0;transition:none;transform:none}.navbar-expand-lg .offcanvas-bottom,.navbar-expand-lg .offcanvas-top{height:auto;border-top:0;border-bottom:0}.navbar-expand-lg .offcanvas-body{display:flex;flex-grow:0;padding:0;overflow-y:visible}}@media (min-width:1200px){.navbar-expand-xl{flex-wrap:nowrap;justify-content:flex-start}.navbar-expand-xl .navbar-nav{flex-direction:row}.navbar-expand-xl .navbar-nav .dropdown-menu{position:absolute}.navbar-expand-xl .navbar-nav .nav-link{padding-right:.5rem;padding-left:.5rem}.navbar-expand-xl .navbar-nav-scroll{overflow:visible}.navbar-expand-xl .navbar-collapse{display:flex!important;flex-basis:auto}.navbar-expand-xl .navbar-toggler{display:none}.navbar-expand-xl .offcanvas-header{display:none}.navbar-expand-xl .offcanvas{position:inherit;bottom:0;z-index:1000;flex-grow:1;visibility:visible!important;background-color:transparent;border-right:0;border-left:0;transition:none;transform:none}.navbar-expand-xl .offcanvas-bottom,.navbar-expand-xl .offcanvas-top{height:auto;border-top:0;border-bottom:0}.navbar-expand-xl .offcanvas-body{display:flex;flex-grow:0;padding:0;overflow-y:visible}}@media (min-width:1400px){.navbar-expand-xxl{flex-wrap:nowrap;justify-content:flex-start}.navbar-expand-xxl .navbar-nav{flex-direction:row}.navbar-expand-xxl .navbar-nav .dropdown-menu{position:absolute}.navbar-expand-xxl .navbar-nav .nav-link{padding-right:.5rem;padding-left:.5rem}.navbar-expand-xxl .navbar-nav-scroll{overflow:visible}.navbar-expand-xxl .navbar-collapse{display:flex!important;flex-basis:auto}.navbar-expand-xxl .navbar-toggler{display:none}.navbar-expand-xxl .offcanvas-header{display:none}.navbar-expand-xxl .offcanvas{position:inherit;bottom:0;z-index:1000;flex-grow:1;visibility:visible!important;background-color:transparent;border-right:0;border-left:0;transition:none;transform:none}.navbar-expand-xxl .offcanvas-bottom,.navbar-expand-xxl .offcanvas-top{height:auto;border-top:0;border-bottom:0}.navbar-expand-xxl .offcanvas-body{display:flex;flex-grow:0;padding:0;overflow-y:visible}}.navbar-expand{flex-wrap:nowrap;justify-content:flex-start}.navbar-expand .navbar-nav{flex-direction:row}.navbar-expand .navbar-nav .dropdown-menu{position:absolute}.navbar-expand .navbar-nav .nav-link{padding-right:.5rem;padding-left:.5rem}.navbar-expand .navbar-nav-scroll{overflow:visible}.navbar-expand .navbar-collapse{display:flex!important;flex-basis:auto}.navbar-expand .navbar-toggler{display:none}.navbar-expand .offcanvas-header{display:none}.navbar-expand .offcanvas{position:inherit;bottom:0;z-index:1000;flex-grow:1;visibility:visible!important;background-color:transparent;border-right:0;border-left:0;transition:none;transform:none}.navbar-expand .offcanvas-bottom,.navbar-expand .offcanvas-top{height:auto;border-top:0;border-bottom:0}.navbar-expand .offcanvas-body{display:flex;flex-grow:0;padding:0;overflow-y:visible}.navbar-light .navbar-brand{color:rgba(0,0,0,.9)}.navbar-light .navbar-brand:focus,.navbar-light .navbar-brand:hover{color:rgba(0,0,0,.9)}.navbar-light .navbar-nav .nav-link{color:rgba(0,0,0,.55)}.navbar-light .navbar-nav .nav-link:focus,.navbar-light .navbar-nav .nav-link:hover{color:rgba(0,0,0,.7)}.navbar-light .navbar-nav .nav-link.disabled{color:rgba(0,0,0,.3)}.navbar-light .navbar-nav .nav-link.active,.navbar-light .navbar-nav .show>.nav-link{color:rgba(0,0,0,.9)}.navbar-light .navbar-toggler{color:rgba(0,0,0,.55);border-color:rgba(0,0,0,.1)}.navbar-light .navbar-toggler-icon{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%280, 0, 0, 0.55%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e")}.navbar-light .navbar-text{color:rgba(0,0,0,.55)}.navbar-light .navbar-text a,.navbar-light .navbar-text a:focus,.navbar-light .navbar-text a:hover{color:rgba(0,0,0,.9)}.navbar-dark .navbar-brand{color:#fff}.navbar-dark .navbar-brand:focus,.navbar-dark .navbar-brand:hover{color:#fff}.navbar-dark .navbar-nav .nav-link{color:rgba(255,255,255,.55)}.navbar-dark .navbar-nav .nav-link:focus,.navbar-dark .navbar-nav .nav-link:hover{color:rgba(255,255,255,.75)}.navbar-dark .navbar-nav .nav-link.disabled{color:rgba(255,255,255,.25)}.navbar-dark .navbar-nav .nav-link.active,.navbar-dark .navbar-nav .show>.nav-link{color:#fff}.navbar-dark .navbar-toggler{color:rgba(255,255,255,.55);border-color:rgba(255,255,255,.1)}.navbar-dark .navbar-toggler-icon{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.55%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e")}.navbar-dark .navbar-text{color:rgba(255,255,255,.55)}.navbar-dark .navbar-text a,.navbar-dark .navbar-text a:focus,.navbar-dark .navbar-text a:hover{color:#fff}.card{position:relative;display:flex;flex-direction:column;min-width:0;word-wrap:break-word;background-color:#fff;background-clip:border-box;border:1px solid rgba(0,0,0,.125);border-radius:.25rem}.card>hr{margin-right:0;margin-left:0}.card>.list-group{border-top:inherit;border-bottom:inherit}.card>.list-group:first-child{border-top-width:0;border-top-left-radius:calc(.25rem - 1px);border-top-right-radius:calc(.25rem - 1px)}.card>.list-group:last-child{border-bottom-width:0;border-bottom-right-radius:calc(.25rem - 1px);border-bottom-left-radius:calc(.25rem - 1px)}.card>.card-header+.list-group,.card>.list-group+.card-footer{border-top:0}.card-body{flex:1 1 auto;padding:1rem 1rem}.card-title{margin-bottom:.5rem}.card-subtitle{margin-top:-.25rem;margin-bottom:0}.card-text:last-child{margin-bottom:0}.card-link+.card-link{margin-left:1rem}.card-header{padding:.5rem 1rem;margin-bottom:0;background-color:rgba(0,0,0,.03);border-bottom:1px solid rgba(0,0,0,.125)}.card-header:first-child{border-radius:calc(.25rem - 1px) calc(.25rem - 1px) 0 0}.card-footer{padding:.5rem 1rem;background-color:rgba(0,0,0,.03);border-top:1px solid rgba(0,0,0,.125)}.card-footer:last-child{border-radius:0 0 calc(.25rem - 1px) calc(.25rem - 1px)}.card-header-tabs{margin-right:-.5rem;margin-bottom:-.5rem;margin-left:-.5rem;border-bottom:0}.card-header-pills{margin-right:-.5rem;margin-left:-.5rem}.card-img-overlay{position:absolute;top:0;right:0;bottom:0;left:0;padding:1rem;border-radius:calc(.25rem - 1px)}.card-img,.card-img-bottom,.card-img-top{width:100%}.card-img,.card-img-top{border-top-left-radius:calc(.25rem - 1px);border-top-right-radius:calc(.25rem - 1px)}.card-img,.card-img-bottom{border-bottom-right-radius:calc(.25rem - 1px);border-bottom-left-radius:calc(.25rem - 1px)}.card-group>.card{margin-bottom:.75rem}@media (min-width:576px){.card-group{display:flex;flex-flow:row wrap}.card-group>.card{flex:1 0 0%;margin-bottom:0}.card-group>.card+.card{margin-left:0;border-left:0}.card-group>.card:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.card-group>.card:not(:last-child) .card-header,.card-group>.card:not(:last-child) .card-img-top{border-top-right-radius:0}.card-group>.card:not(:last-child) .card-footer,.card-group>.card:not(:last-child) .card-img-bottom{border-bottom-right-radius:0}.card-group>.card:not(:first-child){border-top-left-radius:0;border-bottom-left-radius:0}.card-group>.card:not(:first-child) .card-header,.card-group>.card:not(:first-child) .card-img-top{border-top-left-radius:0}.card-group>.card:not(:first-child) .card-footer,.card-group>.card:not(:first-child) .card-img-bottom{border-bottom-left-radius:0}}.accordion-button{position:relative;display:flex;align-items:center;width:100%;padding:1rem 1.25rem;font-size:1rem;color:#212529;text-align:left;background-color:#fff;border:0;border-radius:0;overflow-anchor:none;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out,border-radius .15s ease}@media (prefers-reduced-motion:reduce){.accordion-button{transition:none}}.accordion-button:not(.collapsed){color:#3467aa;background-color:#ebf1f8;box-shadow:inset 0 -1px 0 rgba(0,0,0,.125)}.accordion-button:not(.collapsed)::after{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%233467aa'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");transform:rotate(-180deg)}.accordion-button::after{flex-shrink:0;width:1.25rem;height:1.25rem;margin-left:auto;content:"";background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23212529'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");background-repeat:no-repeat;background-size:1.25rem;transition:transform .2s ease-in-out}@media (prefers-reduced-motion:reduce){.accordion-button::after{transition:none}}.accordion-button:hover{z-index:2}.accordion-button:focus{z-index:3;border-color:#9db9de;outline:0;box-shadow:0 0 0 .25rem rgba(58,114,189,.25)}.accordion-header{margin-bottom:0}.accordion-item{background-color:#fff;border:1px solid rgba(0,0,0,.125)}.accordion-item:first-of-type{border-top-left-radius:.25rem;border-top-right-radius:.25rem}.accordion-item:first-of-type .accordion-button{border-top-left-radius:calc(.25rem - 1px);border-top-right-radius:calc(.25rem - 1px)}.accordion-item:not(:first-of-type){border-top:0}.accordion-item:last-of-type{border-bottom-right-radius:.25rem;border-bottom-left-radius:.25rem}.accordion-item:last-of-type .accordion-button.collapsed{border-bottom-right-radius:calc(.25rem - 1px);border-bottom-left-radius:calc(.25rem - 1px)}.accordion-item:last-of-type .accordion-collapse{border-bottom-right-radius:.25rem;border-bottom-left-radius:.25rem}.accordion-body{padding:1rem 1.25rem}.accordion-flush .accordion-collapse{border-width:0}.accordion-flush .accordion-item{border-right:0;border-left:0;border-radius:0}.accordion-flush .accordion-item:first-child{border-top:0}.accordion-flush .accordion-item:last-child{border-bottom:0}.accordion-flush .accordion-item .accordion-button{border-radius:0}.breadcrumb{display:flex;flex-wrap:wrap;padding:0 0;margin-bottom:1rem;list-style:none}.breadcrumb-item+.breadcrumb-item{padding-left:.5rem}.breadcrumb-item+.breadcrumb-item::before{float:left;padding-right:.5rem;color:#6c757d;content:var(--bs-breadcrumb-divider, "/")}.breadcrumb-item.active{color:#6c757d}.pagination{display:flex;padding-left:0;list-style:none}.page-link{position:relative;display:block;color:#3a72bd;text-decoration:none;background-color:#fff;border:1px solid #dee2e6;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}@media (prefers-reduced-motion:reduce){.page-link{transition:none}}.page-link:hover{z-index:2;color:#2e5b97;background-color:#e9ecef;border-color:#dee2e6}.page-link:focus{z-index:3;color:#2e5b97;background-color:#e9ecef;outline:0;box-shadow:0 0 0 .25rem rgba(58,114,189,.25)}.page-item:not(:first-child) .page-link{margin-left:-1px}.page-item.active .page-link{z-index:3;color:#fff;background-color:#3a72bd;border-color:#3a72bd}.page-item.disabled .page-link{color:#6c757d;pointer-events:none;background-color:#fff;border-color:#dee2e6}.page-link{padding:.375rem .75rem}.page-item:first-child .page-link{border-top-left-radius:.25rem;border-bottom-left-radius:.25rem}.page-item:last-child .page-link{border-top-right-radius:.25rem;border-bottom-right-radius:.25rem}.pagination-lg .page-link{padding:.75rem 1.5rem;font-size:1.25rem}.pagination-lg .page-item:first-child .page-link{border-top-left-radius:.3rem;border-bottom-left-radius:.3rem}.pagination-lg .page-item:last-child .page-link{border-top-right-radius:.3rem;border-bottom-right-radius:.3rem}.pagination-sm .page-link{padding:.25rem .5rem;font-size:.875rem}.pagination-sm .page-item:first-child .page-link{border-top-left-radius:.2rem;border-bottom-left-radius:.2rem}.pagination-sm .page-item:last-child .page-link{border-top-right-radius:.2rem;border-bottom-right-radius:.2rem}.badge{display:inline-block;padding:.35em .65em;font-size:.75em;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;border-radius:.25rem}.badge:empty{display:none}.btn .badge{position:relative;top:-1px}.alert{position:relative;padding:1rem 1rem;margin-bottom:1rem;border:1px solid transparent;border-radius:.25rem}.alert-heading{color:inherit}.alert-link{font-weight:700}.alert-dismissible{padding-right:3rem}.alert-dismissible .btn-close{position:absolute;top:0;right:0;z-index:2;padding:1.25rem 1rem}.alert-primary{color:#234471;background-color:#d8e3f2;border-color:#c4d5eb}.alert-primary .alert-link{color:#1c365a}.alert-secondary{color:#41464b;background-color:#e2e3e5;border-color:#d3d6d8}.alert-secondary .alert-link{color:#34383c}.alert-success{color:#1d6637;background-color:#d6eede;border-color:#c1e6ce}.alert-success .alert-link{color:#17522c}.alert-info{color:#0e616e;background-color:#d1ecf1;border-color:#b9e3ea}.alert-info .alert-link{color:#0b4e58}.alert-warning{color:#8e660d;background-color:#fbeed0;border-color:#fae6b9}.alert-warning .alert-link{color:#72520a}.alert-danger{color:#842029;background-color:#f8d7da;border-color:#f5c2c7}.alert-danger .alert-link{color:#6a1a21}.alert-light{color:#959596;background-color:#fefefe;border-color:#fdfdfe}.alert-light .alert-link{color:#777778}.alert-dark{color:#141619;background-color:#d3d3d4;border-color:#bcbebf}.alert-dark .alert-link{color:#101214}@-webkit-keyframes progress-bar-stripes{0%{background-position-x:1rem}}@keyframes progress-bar-stripes{0%{background-position-x:1rem}}.progress{display:flex;height:1rem;overflow:hidden;font-size:.75rem;background-color:#e9ecef;border-radius:.25rem}.progress-bar{display:flex;flex-direction:column;justify-content:center;overflow:hidden;color:#fff;text-align:center;white-space:nowrap;background-color:#3a72bd;transition:width .6s ease}@media (prefers-reduced-motion:reduce){.progress-bar{transition:none}}.progress-bar-striped{background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-size:1rem 1rem}.progress-bar-animated{-webkit-animation:1s linear infinite progress-bar-stripes;animation:1s linear infinite progress-bar-stripes}@media (prefers-reduced-motion:reduce){.progress-bar-animated{-webkit-animation:none;animation:none}}.list-group{display:flex;flex-direction:column;padding-left:0;margin-bottom:0;border-radius:.25rem}.list-group-numbered{list-style-type:none;counter-reset:section}.list-group-numbered>li::before{content:counters(section, ".") ". ";counter-increment:section}.list-group-item-action{width:100%;color:#495057;text-align:inherit}.list-group-item-action:focus,.list-group-item-action:hover{z-index:1;color:#495057;text-decoration:none;background-color:#f8f9fa}.list-group-item-action:active{color:#212529;background-color:#e9ecef}.list-group-item{position:relative;display:block;padding:.5rem 1rem;color:#212529;text-decoration:none;background-color:#fff;border:1px solid rgba(0,0,0,.125)}.list-group-item:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}.list-group-item:last-child{border-bottom-right-radius:inherit;border-bottom-left-radius:inherit}.list-group-item.disabled,.list-group-item:disabled{color:#6c757d;pointer-events:none;background-color:#fff}.list-group-item.active{z-index:2;color:#fff;background-color:#3a72bd;border-color:#3a72bd}.list-group-item+.list-group-item{border-top-width:0}.list-group-item+.list-group-item.active{margin-top:-1px;border-top-width:1px}.list-group-horizontal{flex-direction:row}.list-group-horizontal>.list-group-item:first-child{border-bottom-left-radius:.25rem;border-top-right-radius:0}.list-group-horizontal>.list-group-item:last-child{border-top-right-radius:.25rem;border-bottom-left-radius:0}.list-group-horizontal>.list-group-item.active{margin-top:0}.list-group-horizontal>.list-group-item+.list-group-item{border-top-width:1px;border-left-width:0}.list-group-horizontal>.list-group-item+.list-group-item.active{margin-left:-1px;border-left-width:1px}@media (min-width:576px){.list-group-horizontal-sm{flex-direction:row}.list-group-horizontal-sm>.list-group-item:first-child{border-bottom-left-radius:.25rem;border-top-right-radius:0}.list-group-horizontal-sm>.list-group-item:last-child{border-top-right-radius:.25rem;border-bottom-left-radius:0}.list-group-horizontal-sm>.list-group-item.active{margin-top:0}.list-group-horizontal-sm>.list-group-item+.list-group-item{border-top-width:1px;border-left-width:0}.list-group-horizontal-sm>.list-group-item+.list-group-item.active{margin-left:-1px;border-left-width:1px}}@media (min-width:768px){.list-group-horizontal-md{flex-direction:row}.list-group-horizontal-md>.list-group-item:first-child{border-bottom-left-radius:.25rem;border-top-right-radius:0}.list-group-horizontal-md>.list-group-item:last-child{border-top-right-radius:.25rem;border-bottom-left-radius:0}.list-group-horizontal-md>.list-group-item.active{margin-top:0}.list-group-horizontal-md>.list-group-item+.list-group-item{border-top-width:1px;border-left-width:0}.list-group-horizontal-md>.list-group-item+.list-group-item.active{margin-left:-1px;border-left-width:1px}}@media (min-width:992px){.list-group-horizontal-lg{flex-direction:row}.list-group-horizontal-lg>.list-group-item:first-child{border-bottom-left-radius:.25rem;border-top-right-radius:0}.list-group-horizontal-lg>.list-group-item:last-child{border-top-right-radius:.25rem;border-bottom-left-radius:0}.list-group-horizontal-lg>.list-group-item.active{margin-top:0}.list-group-horizontal-lg>.list-group-item+.list-group-item{border-top-width:1px;border-left-width:0}.list-group-horizontal-lg>.list-group-item+.list-group-item.active{margin-left:-1px;border-left-width:1px}}@media (min-width:1200px){.list-group-horizontal-xl{flex-direction:row}.list-group-horizontal-xl>.list-group-item:first-child{border-bottom-left-radius:.25rem;border-top-right-radius:0}.list-group-horizontal-xl>.list-group-item:last-child{border-top-right-radius:.25rem;border-bottom-left-radius:0}.list-group-horizontal-xl>.list-group-item.active{margin-top:0}.list-group-horizontal-xl>.list-group-item+.list-group-item{border-top-width:1px;border-left-width:0}.list-group-horizontal-xl>.list-group-item+.list-group-item.active{margin-left:-1px;border-left-width:1px}}@media (min-width:1400px){.list-group-horizontal-xxl{flex-direction:row}.list-group-horizontal-xxl>.list-group-item:first-child{border-bottom-left-radius:.25rem;border-top-right-radius:0}.list-group-horizontal-xxl>.list-group-item:last-child{border-top-right-radius:.25rem;border-bottom-left-radius:0}.list-group-horizontal-xxl>.list-group-item.active{margin-top:0}.list-group-horizontal-xxl>.list-group-item+.list-group-item{border-top-width:1px;border-left-width:0}.list-group-horizontal-xxl>.list-group-item+.list-group-item.active{margin-left:-1px;border-left-width:1px}}.list-group-flush{border-radius:0}.list-group-flush>.list-group-item{border-width:0 0 1px}.list-group-flush>.list-group-item:last-child{border-bottom-width:0}.list-group-item-primary{color:#234471;background-color:#d8e3f2}.list-group-item-primary.list-group-item-action:focus,.list-group-item-primary.list-group-item-action:hover{color:#234471;background-color:#c2ccda}.list-group-item-primary.list-group-item-action.active{color:#fff;background-color:#234471;border-color:#234471}.list-group-item-secondary{color:#41464b;background-color:#e2e3e5}.list-group-item-secondary.list-group-item-action:focus,.list-group-item-secondary.list-group-item-action:hover{color:#41464b;background-color:#cbccce}.list-group-item-secondary.list-group-item-action.active{color:#fff;background-color:#41464b;border-color:#41464b}.list-group-item-success{color:#1d6637;background-color:#d6eede}.list-group-item-success.list-group-item-action:focus,.list-group-item-success.list-group-item-action:hover{color:#1d6637;background-color:#c1d6c8}.list-group-item-success.list-group-item-action.active{color:#fff;background-color:#1d6637;border-color:#1d6637}.list-group-item-info{color:#0e616e;background-color:#d1ecf1}.list-group-item-info.list-group-item-action:focus,.list-group-item-info.list-group-item-action:hover{color:#0e616e;background-color:#bcd4d9}.list-group-item-info.list-group-item-action.active{color:#fff;background-color:#0e616e;border-color:#0e616e}.list-group-item-warning{color:#8e660d;background-color:#fbeed0}.list-group-item-warning.list-group-item-action:focus,.list-group-item-warning.list-group-item-action:hover{color:#8e660d;background-color:#e2d6bb}.list-group-item-warning.list-group-item-action.active{color:#fff;background-color:#8e660d;border-color:#8e660d}.list-group-item-danger{color:#842029;background-color:#f8d7da}.list-group-item-danger.list-group-item-action:focus,.list-group-item-danger.list-group-item-action:hover{color:#842029;background-color:#dfc2c4}.list-group-item-danger.list-group-item-action.active{color:#fff;background-color:#842029;border-color:#842029}.list-group-item-light{color:#959596;background-color:#fefefe}.list-group-item-light.list-group-item-action:focus,.list-group-item-light.list-group-item-action:hover{color:#959596;background-color:#e5e5e5}.list-group-item-light.list-group-item-action.active{color:#fff;background-color:#959596;border-color:#959596}.list-group-item-dark{color:#141619;background-color:#d3d3d4}.list-group-item-dark.list-group-item-action:focus,.list-group-item-dark.list-group-item-action:hover{color:#141619;background-color:#bebebf}.list-group-item-dark.list-group-item-action.active{color:#fff;background-color:#141619;border-color:#141619}.btn-close{box-sizing:content-box;width:1em;height:1em;padding:.25em .25em;color:#000;background:transparent url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3e%3cpath d='M.293.293a1 1 0 011.414 0L8 6.586 14.293.293a1 1 0 111.414 1.414L9.414 8l6.293 6.293a1 1 0 01-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 01-1.414-1.414L6.586 8 .293 1.707a1 1 0 010-1.414z'/%3e%3c/svg%3e") center/1em auto no-repeat;border:0;border-radius:.25rem;opacity:.5}.btn-close:hover{color:#000;text-decoration:none;opacity:.75}.btn-close:focus{outline:0;box-shadow:0 0 0 .25rem rgba(58,114,189,.25);opacity:1}.btn-close.disabled,.btn-close:disabled{pointer-events:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:.25}.btn-close-white{filter:invert(1) grayscale(100%) brightness(200%)}.toast{width:350px;max-width:100%;font-size:.875rem;pointer-events:auto;background-color:rgba(255,255,255,.85);background-clip:padding-box;border:1px solid rgba(0,0,0,.1);box-shadow:0 .5rem 1rem rgba(0,0,0,.15);border-radius:.25rem}.toast.showing{opacity:0}.toast:not(.show){display:none}.toast-container{width:-webkit-max-content;width:-moz-max-content;width:max-content;max-width:100%;pointer-events:none}.toast-container>:not(:last-child){margin-bottom:.75rem}.toast-header{display:flex;align-items:center;padding:.5rem .75rem;color:#6c757d;background-color:rgba(255,255,255,.85);background-clip:padding-box;border-bottom:1px solid rgba(0,0,0,.05);border-top-left-radius:calc(.25rem - 1px);border-top-right-radius:calc(.25rem - 1px)}.toast-header .btn-close{margin-right:-.375rem;margin-left:.75rem}.toast-body{padding:.75rem;word-wrap:break-word}.modal{position:fixed;top:0;left:0;z-index:1055;display:none;width:100%;height:100%;overflow-x:hidden;overflow-y:auto;outline:0}.modal-dialog{position:relative;width:auto;margin:.5rem;pointer-events:none}.modal.fade .modal-dialog{transition:transform .3s ease-out;transform:translate(0,-50px)}@media (prefers-reduced-motion:reduce){.modal.fade .modal-dialog{transition:none}}.modal.show .modal-dialog{transform:none}.modal.modal-static .modal-dialog{transform:scale(1.02)}.modal-dialog-scrollable{height:calc(100% - 1rem)}.modal-dialog-scrollable .modal-content{max-height:100%;overflow:hidden}.modal-dialog-scrollable .modal-body{overflow-y:auto}.modal-dialog-centered{display:flex;align-items:center;min-height:calc(100% - 1rem)}.modal-content{position:relative;display:flex;flex-direction:column;width:100%;pointer-events:auto;background-color:#fff;background-clip:padding-box;border:1px solid rgba(0,0,0,.2);border-radius:.3rem;outline:0}.modal-backdrop{position:fixed;top:0;left:0;z-index:1050;width:100vw;height:100vh;background-color:#000}.modal-backdrop.fade{opacity:0}.modal-backdrop.show{opacity:.5}.modal-header{display:flex;flex-shrink:0;align-items:center;justify-content:space-between;padding:1rem 1rem;border-bottom:1px solid #dee2e6;border-top-left-radius:calc(.3rem - 1px);border-top-right-radius:calc(.3rem - 1px)}.modal-header .btn-close{padding:.5rem .5rem;margin:-.5rem -.5rem -.5rem auto}.modal-title{margin-bottom:0;line-height:1.5}.modal-body{position:relative;flex:1 1 auto;padding:1rem}.modal-footer{display:flex;flex-wrap:wrap;flex-shrink:0;align-items:center;justify-content:flex-end;padding:.75rem;border-top:1px solid #dee2e6;border-bottom-right-radius:calc(.3rem - 1px);border-bottom-left-radius:calc(.3rem - 1px)}.modal-footer>*{margin:.25rem}@media (min-width:576px){.modal-dialog{max-width:500px;margin:1.75rem auto}.modal-dialog-scrollable{height:calc(100% - 3.5rem)}.modal-dialog-centered{min-height:calc(100% - 3.5rem)}.modal-sm{max-width:300px}}@media (min-width:992px){.modal-lg,.modal-xl{max-width:800px}}@media (min-width:1200px){.modal-xl{max-width:1140px}}.modal-fullscreen{width:100vw;max-width:none;height:100%;margin:0}.modal-fullscreen .modal-content{height:100%;border:0;border-radius:0}.modal-fullscreen .modal-header{border-radius:0}.modal-fullscreen .modal-body{overflow-y:auto}.modal-fullscreen .modal-footer{border-radius:0}@media (max-width:575.98px){.modal-fullscreen-sm-down{width:100vw;max-width:none;height:100%;margin:0}.modal-fullscreen-sm-down .modal-content{height:100%;border:0;border-radius:0}.modal-fullscreen-sm-down .modal-header{border-radius:0}.modal-fullscreen-sm-down .modal-body{overflow-y:auto}.modal-fullscreen-sm-down .modal-footer{border-radius:0}}@media (max-width:767.98px){.modal-fullscreen-md-down{width:100vw;max-width:none;height:100%;margin:0}.modal-fullscreen-md-down .modal-content{height:100%;border:0;border-radius:0}.modal-fullscreen-md-down .modal-header{border-radius:0}.modal-fullscreen-md-down .modal-body{overflow-y:auto}.modal-fullscreen-md-down .modal-footer{border-radius:0}}@media (max-width:991.98px){.modal-fullscreen-lg-down{width:100vw;max-width:none;height:100%;margin:0}.modal-fullscreen-lg-down .modal-content{height:100%;border:0;border-radius:0}.modal-fullscreen-lg-down .modal-header{border-radius:0}.modal-fullscreen-lg-down .modal-body{overflow-y:auto}.modal-fullscreen-lg-down .modal-footer{border-radius:0}}@media (max-width:1199.98px){.modal-fullscreen-xl-down{width:100vw;max-width:none;height:100%;margin:0}.modal-fullscreen-xl-down .modal-content{height:100%;border:0;border-radius:0}.modal-fullscreen-xl-down .modal-header{border-radius:0}.modal-fullscreen-xl-down .modal-body{overflow-y:auto}.modal-fullscreen-xl-down .modal-footer{border-radius:0}}@media (max-width:1399.98px){.modal-fullscreen-xxl-down{width:100vw;max-width:none;height:100%;margin:0}.modal-fullscreen-xxl-down .modal-content{height:100%;border:0;border-radius:0}.modal-fullscreen-xxl-down .modal-header{border-radius:0}.modal-fullscreen-xxl-down .modal-body{overflow-y:auto}.modal-fullscreen-xxl-down .modal-footer{border-radius:0}}.tooltip{position:absolute;z-index:1080;display:block;margin:0;font-family:var(--bs-font-sans-serif);font-style:normal;font-weight:400;line-height:1.5;text-align:left;text-align:start;text-decoration:none;text-shadow:none;text-transform:none;letter-spacing:normal;word-break:normal;word-spacing:normal;white-space:normal;line-break:auto;font-size:.875rem;word-wrap:break-word;opacity:0}.tooltip.show{opacity:.9}.tooltip .tooltip-arrow{position:absolute;display:block;width:.8rem;height:.4rem}.tooltip .tooltip-arrow::before{position:absolute;content:"";border-color:transparent;border-style:solid}.bs-tooltip-auto[data-popper-placement^=top],.bs-tooltip-top{padding:.4rem 0}.bs-tooltip-auto[data-popper-placement^=top] .tooltip-arrow,.bs-tooltip-top .tooltip-arrow{bottom:0}.bs-tooltip-auto[data-popper-placement^=top] .tooltip-arrow::before,.bs-tooltip-top .tooltip-arrow::before{top:-1px;border-width:.4rem .4rem 0;border-top-color:#000}.bs-tooltip-auto[data-popper-placement^=right],.bs-tooltip-end{padding:0 .4rem}.bs-tooltip-auto[data-popper-placement^=right] .tooltip-arrow,.bs-tooltip-end .tooltip-arrow{left:0;width:.4rem;height:.8rem}.bs-tooltip-auto[data-popper-placement^=right] .tooltip-arrow::before,.bs-tooltip-end .tooltip-arrow::before{right:-1px;border-width:.4rem .4rem .4rem 0;border-right-color:#000}.bs-tooltip-auto[data-popper-placement^=bottom],.bs-tooltip-bottom{padding:.4rem 0}.bs-tooltip-auto[data-popper-placement^=bottom] .tooltip-arrow,.bs-tooltip-bottom .tooltip-arrow{top:0}.bs-tooltip-auto[data-popper-placement^=bottom] .tooltip-arrow::before,.bs-tooltip-bottom .tooltip-arrow::before{bottom:-1px;border-width:0 .4rem .4rem;border-bottom-color:#000}.bs-tooltip-auto[data-popper-placement^=left],.bs-tooltip-start{padding:0 .4rem}.bs-tooltip-auto[data-popper-placement^=left] .tooltip-arrow,.bs-tooltip-start .tooltip-arrow{right:0;width:.4rem;height:.8rem}.bs-tooltip-auto[data-popper-placement^=left] .tooltip-arrow::before,.bs-tooltip-start .tooltip-arrow::before{left:-1px;border-width:.4rem 0 .4rem .4rem;border-left-color:#000}.tooltip-inner{max-width:200px;padding:.25rem .5rem;color:#fff;text-align:center;background-color:#000;border-radius:.25rem}.popover{position:absolute;top:0;left:0;z-index:1070;display:block;max-width:276px;font-family:var(--bs-font-sans-serif);font-style:normal;font-weight:400;line-height:1.5;text-align:left;text-align:start;text-decoration:none;text-shadow:none;text-transform:none;letter-spacing:normal;word-break:normal;word-spacing:normal;white-space:normal;line-break:auto;font-size:.875rem;word-wrap:break-word;background-color:#fff;background-clip:padding-box;border:1px solid rgba(0,0,0,.2);border-radius:.3rem}.popover .popover-arrow{position:absolute;display:block;width:1rem;height:.5rem}.popover .popover-arrow::after,.popover .popover-arrow::before{position:absolute;display:block;content:"";border-color:transparent;border-style:solid}.bs-popover-auto[data-popper-placement^=top]>.popover-arrow,.bs-popover-top>.popover-arrow{bottom:calc(-.5rem - 1px)}.bs-popover-auto[data-popper-placement^=top]>.popover-arrow::before,.bs-popover-top>.popover-arrow::before{bottom:0;border-width:.5rem .5rem 0;border-top-color:rgba(0,0,0,.25)}.bs-popover-auto[data-popper-placement^=top]>.popover-arrow::after,.bs-popover-top>.popover-arrow::after{bottom:1px;border-width:.5rem .5rem 0;border-top-color:#fff}.bs-popover-auto[data-popper-placement^=right]>.popover-arrow,.bs-popover-end>.popover-arrow{left:calc(-.5rem - 1px);width:.5rem;height:1rem}.bs-popover-auto[data-popper-placement^=right]>.popover-arrow::before,.bs-popover-end>.popover-arrow::before{left:0;border-width:.5rem .5rem .5rem 0;border-right-color:rgba(0,0,0,.25)}.bs-popover-auto[data-popper-placement^=right]>.popover-arrow::after,.bs-popover-end>.popover-arrow::after{left:1px;border-width:.5rem .5rem .5rem 0;border-right-color:#fff}.bs-popover-auto[data-popper-placement^=bottom]>.popover-arrow,.bs-popover-bottom>.popover-arrow{top:calc(-.5rem - 1px)}.bs-popover-auto[data-popper-placement^=bottom]>.popover-arrow::before,.bs-popover-bottom>.popover-arrow::before{top:0;border-width:0 .5rem .5rem .5rem;border-bottom-color:rgba(0,0,0,.25)}.bs-popover-auto[data-popper-placement^=bottom]>.popover-arrow::after,.bs-popover-bottom>.popover-arrow::after{top:1px;border-width:0 .5rem .5rem .5rem;border-bottom-color:#fff}.bs-popover-auto[data-popper-placement^=bottom] .popover-header::before,.bs-popover-bottom .popover-header::before{position:absolute;top:0;left:50%;display:block;width:1rem;margin-left:-.5rem;content:"";border-bottom:1px solid #f0f0f0}.bs-popover-auto[data-popper-placement^=left]>.popover-arrow,.bs-popover-start>.popover-arrow{right:calc(-.5rem - 1px);width:.5rem;height:1rem}.bs-popover-auto[data-popper-placement^=left]>.popover-arrow::before,.bs-popover-start>.popover-arrow::before{right:0;border-width:.5rem 0 .5rem .5rem;border-left-color:rgba(0,0,0,.25)}.bs-popover-auto[data-popper-placement^=left]>.popover-arrow::after,.bs-popover-start>.popover-arrow::after{right:1px;border-width:.5rem 0 .5rem .5rem;border-left-color:#fff}.popover-header{padding:.5rem 1rem;margin-bottom:0;font-size:1rem;background-color:#f0f0f0;border-bottom:1px solid rgba(0,0,0,.2);border-top-left-radius:calc(.3rem - 1px);border-top-right-radius:calc(.3rem - 1px)}.popover-header:empty{display:none}.popover-body{padding:1rem 1rem;color:#212529}.carousel{position:relative}.carousel.pointer-event{touch-action:pan-y}.carousel-inner{position:relative;width:100%;overflow:hidden}.carousel-inner::after{display:block;clear:both;content:""}.carousel-item{position:relative;display:none;float:left;width:100%;margin-right:-100%;-webkit-backface-visibility:hidden;backface-visibility:hidden;transition:transform .6s ease-in-out}@media (prefers-reduced-motion:reduce){.carousel-item{transition:none}}.carousel-item-next,.carousel-item-prev,.carousel-item.active{display:block}.active.carousel-item-end,.carousel-item-next:not(.carousel-item-start){transform:translateX(100%)}.active.carousel-item-start,.carousel-item-prev:not(.carousel-item-end){transform:translateX(-100%)}.carousel-fade .carousel-item{opacity:0;transition-property:opacity;transform:none}.carousel-fade .carousel-item-next.carousel-item-start,.carousel-fade .carousel-item-prev.carousel-item-end,.carousel-fade .carousel-item.active{z-index:1;opacity:1}.carousel-fade .active.carousel-item-end,.carousel-fade .active.carousel-item-start{z-index:0;opacity:0;transition:opacity 0s .6s}@media (prefers-reduced-motion:reduce){.carousel-fade .active.carousel-item-end,.carousel-fade .active.carousel-item-start{transition:none}}.carousel-control-next,.carousel-control-prev{position:absolute;top:0;bottom:0;z-index:1;display:flex;align-items:center;justify-content:center;width:15%;padding:0;color:#fff;text-align:center;background:0 0;border:0;opacity:.5;transition:opacity .15s ease}@media (prefers-reduced-motion:reduce){.carousel-control-next,.carousel-control-prev{transition:none}}.carousel-control-next:focus,.carousel-control-next:hover,.carousel-control-prev:focus,.carousel-control-prev:hover{color:#fff;text-decoration:none;outline:0;opacity:.9}.carousel-control-prev{left:0}.carousel-control-next{right:0}.carousel-control-next-icon,.carousel-control-prev-icon{display:inline-block;width:2rem;height:2rem;background-repeat:no-repeat;background-position:50%;background-size:100% 100%}.carousel-control-prev-icon{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0z'/%3e%3c/svg%3e")}.carousel-control-next-icon{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e")}.carousel-indicators{position:absolute;right:0;bottom:0;left:0;z-index:2;display:flex;justify-content:center;padding:0;margin-right:15%;margin-bottom:1rem;margin-left:15%;list-style:none}.carousel-indicators [data-bs-target]{box-sizing:content-box;flex:0 1 auto;width:30px;height:3px;padding:0;margin-right:3px;margin-left:3px;text-indent:-999px;cursor:pointer;background-color:#fff;background-clip:padding-box;border:0;border-top:10px solid transparent;border-bottom:10px solid transparent;opacity:.5;transition:opacity .6s ease}@media (prefers-reduced-motion:reduce){.carousel-indicators [data-bs-target]{transition:none}}.carousel-indicators .active{opacity:1}.carousel-caption{position:absolute;right:15%;bottom:1.25rem;left:15%;padding-top:1.25rem;padding-bottom:1.25rem;color:#fff;text-align:center}.carousel-dark .carousel-control-next-icon,.carousel-dark .carousel-control-prev-icon{filter:invert(1) grayscale(100)}.carousel-dark .carousel-indicators [data-bs-target]{background-color:#000}.carousel-dark .carousel-caption{color:#000}@-webkit-keyframes spinner-border{to{transform:rotate(360deg)}}@keyframes spinner-border{to{transform:rotate(360deg)}}.spinner-border{display:inline-block;width:2rem;height:2rem;vertical-align:-.125em;border:.25em solid currentColor;border-right-color:transparent;border-radius:50%;-webkit-animation:.75s linear infinite spinner-border;animation:.75s linear infinite spinner-border}.spinner-border-sm{width:1rem;height:1rem;border-width:.2em}@-webkit-keyframes spinner-grow{0%{transform:scale(0)}50%{opacity:1;transform:none}}@keyframes spinner-grow{0%{transform:scale(0)}50%{opacity:1;transform:none}}.spinner-grow{display:inline-block;width:2rem;height:2rem;vertical-align:-.125em;background-color:currentColor;border-radius:50%;opacity:0;-webkit-animation:.75s linear infinite spinner-grow;animation:.75s linear infinite spinner-grow}.spinner-grow-sm{width:1rem;height:1rem}@media (prefers-reduced-motion:reduce){.spinner-border,.spinner-grow{-webkit-animation-duration:1.5s;animation-duration:1.5s}}.offcanvas{position:fixed;bottom:0;z-index:1045;display:flex;flex-direction:column;max-width:100%;visibility:hidden;background-color:#fff;background-clip:padding-box;outline:0;transition:transform .3s ease-in-out}@media (prefers-reduced-motion:reduce){.offcanvas{transition:none}}.offcanvas-backdrop{position:fixed;top:0;left:0;z-index:1040;width:100vw;height:100vh;background-color:#000}.offcanvas-backdrop.fade{opacity:0}.offcanvas-backdrop.show{opacity:.5}.offcanvas-header{display:flex;align-items:center;justify-content:space-between;padding:1rem 1rem}.offcanvas-header .btn-close{padding:.5rem .5rem;margin-top:-.5rem;margin-right:-.5rem;margin-bottom:-.5rem}.offcanvas-title{margin-bottom:0;line-height:1.5}.offcanvas-body{flex-grow:1;padding:1rem 1rem;overflow-y:auto}.offcanvas-start{top:0;left:0;width:400px;border-right:1px solid rgba(0,0,0,.2);transform:translateX(-100%)}.offcanvas-end{top:0;right:0;width:400px;border-left:1px solid rgba(0,0,0,.2);transform:translateX(100%)}.offcanvas-top{top:0;right:0;left:0;height:30vh;max-height:100%;border-bottom:1px solid rgba(0,0,0,.2);transform:translateY(-100%)}.offcanvas-bottom{right:0;left:0;height:30vh;max-height:100%;border-top:1px solid rgba(0,0,0,.2);transform:translateY(100%)}.offcanvas.show{transform:none}.placeholder{display:inline-block;min-height:1em;vertical-align:middle;cursor:wait;background-color:currentColor;opacity:.5}.placeholder.btn::before{display:inline-block;content:""}.placeholder-xs{min-height:.6em}.placeholder-sm{min-height:.8em}.placeholder-lg{min-height:1.2em}.placeholder-glow .placeholder{-webkit-animation:placeholder-glow 2s ease-in-out infinite;animation:placeholder-glow 2s ease-in-out infinite}@-webkit-keyframes placeholder-glow{50%{opacity:.2}}@keyframes placeholder-glow{50%{opacity:.2}}.placeholder-wave{-webkit-mask-image:linear-gradient(130deg,#000 55%,rgba(0,0,0,0.8) 75%,#000 95%);mask-image:linear-gradient(130deg,#000 55%,rgba(0,0,0,0.8) 75%,#000 95%);-webkit-mask-size:200% 100%;mask-size:200% 100%;-webkit-animation:placeholder-wave 2s linear infinite;animation:placeholder-wave 2s linear infinite}@-webkit-keyframes placeholder-wave{100%{-webkit-mask-position:-200% 0%;mask-position:-200% 0%}}@keyframes placeholder-wave{100%{-webkit-mask-position:-200% 0%;mask-position:-200% 0%}}.clearfix::after{display:block;clear:both;content:""}.link-primary{color:#3a72bd}.link-primary:focus,.link-primary:hover{color:#2e5b97}.link-secondary{color:#6c757d}.link-secondary:focus,.link-secondary:hover{color:#565e64}.link-success{color:#30aa5b}.link-success:focus,.link-success:hover{color:#268849}.link-info{color:#17a2b8}.link-info:focus,.link-info:hover{color:#128293}.link-warning{color:#edaa16}.link-warning:focus,.link-warning:hover{color:#be8812}.link-danger{color:#dc3545}.link-danger:focus,.link-danger:hover{color:#b02a37}.link-light{color:#f8f9fa}.link-light:focus,.link-light:hover{color:#f9fafb}.link-dark{color:#212529}.link-dark:focus,.link-dark:hover{color:#1a1e21}.ratio{position:relative;width:100%}.ratio::before{display:block;padding-top:var(--bs-aspect-ratio);content:""}.ratio>*{position:absolute;top:0;left:0;width:100%;height:100%}.ratio-1x1{--bs-aspect-ratio:100%}.ratio-4x3{--bs-aspect-ratio:calc(3 / 4 * 100%)}.ratio-16x9{--bs-aspect-ratio:calc(9 / 16 * 100%)}.ratio-21x9{--bs-aspect-ratio:calc(9 / 21 * 100%)}.fixed-top{position:fixed;top:0;right:0;left:0;z-index:1030}.fixed-bottom{position:fixed;right:0;bottom:0;left:0;z-index:1030}.sticky-top{position:-webkit-sticky;position:sticky;top:0;z-index:1020}@media (min-width:576px){.sticky-sm-top{position:-webkit-sticky;position:sticky;top:0;z-index:1020}}@media (min-width:768px){.sticky-md-top{position:-webkit-sticky;position:sticky;top:0;z-index:1020}}@media (min-width:992px){.sticky-lg-top{position:-webkit-sticky;position:sticky;top:0;z-index:1020}}@media (min-width:1200px){.sticky-xl-top{position:-webkit-sticky;position:sticky;top:0;z-index:1020}}@media (min-width:1400px){.sticky-xxl-top{position:-webkit-sticky;position:sticky;top:0;z-index:1020}}.hstack{display:flex;flex-direction:row;align-items:center;align-self:stretch}.vstack{display:flex;flex:1 1 auto;flex-direction:column;align-self:stretch}.visually-hidden,.visually-hidden-focusable:not(:focus):not(:focus-within){position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}.stretched-link::after{position:absolute;top:0;right:0;bottom:0;left:0;z-index:1;content:""}.text-truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.vr{display:inline-block;align-self:stretch;width:1px;min-height:1em;background-color:currentColor;opacity:.25}.align-baseline{vertical-align:baseline!important}.align-top{vertical-align:top!important}.align-middle{vertical-align:middle!important}.align-bottom{vertical-align:bottom!important}.align-text-bottom{vertical-align:text-bottom!important}.align-text-top{vertical-align:text-top!important}.float-start{float:left!important}.float-end{float:right!important}.float-none{float:none!important}.opacity-0{opacity:0!important}.opacity-25{opacity:.25!important}.opacity-50{opacity:.5!important}.opacity-75{opacity:.75!important}.opacity-100{opacity:1!important}.overflow-auto{overflow:auto!important}.overflow-hidden{overflow:hidden!important}.overflow-visible{overflow:visible!important}.overflow-scroll{overflow:scroll!important}.d-inline{display:inline!important}.d-inline-block{display:inline-block!important}.d-block{display:block!important}.d-grid{display:grid!important}.d-table{display:table!important}.d-table-row{display:table-row!important}.d-table-cell{display:table-cell!important}.d-flex{display:flex!important}.d-inline-flex{display:inline-flex!important}.d-none{display:none!important}.shadow{box-shadow:0 .5rem 1rem rgba(0,0,0,.15)!important}.shadow-sm{box-shadow:0 .125rem .25rem rgba(0,0,0,.075)!important}.shadow-lg{box-shadow:0 1rem 3rem rgba(0,0,0,.175)!important}.shadow-none{box-shadow:none!important}.position-static{position:static!important}.position-relative{position:relative!important}.position-absolute{position:absolute!important}.position-fixed{position:fixed!important}.position-sticky{position:-webkit-sticky!important;position:sticky!important}.top-0{top:0!important}.top-50{top:50%!important}.top-100{top:100%!important}.bottom-0{bottom:0!important}.bottom-50{bottom:50%!important}.bottom-100{bottom:100%!important}.start-0{left:0!important}.start-50{left:50%!important}.start-100{left:100%!important}.end-0{right:0!important}.end-50{right:50%!important}.end-100{right:100%!important}.translate-middle{transform:translate(-50%,-50%)!important}.translate-middle-x{transform:translateX(-50%)!important}.translate-middle-y{transform:translateY(-50%)!important}.border{border:1px solid #dee2e6!important}.border-0{border:0!important}.border-top{border-top:1px solid #dee2e6!important}.border-top-0{border-top:0!important}.border-end{border-right:1px solid #dee2e6!important}.border-end-0{border-right:0!important}.border-bottom{border-bottom:1px solid #dee2e6!important}.border-bottom-0{border-bottom:0!important}.border-start{border-left:1px solid #dee2e6!important}.border-start-0{border-left:0!important}.border-primary{border-color:#3a72bd!important}.border-secondary{border-color:#6c757d!important}.border-success{border-color:#30aa5b!important}.border-info{border-color:#17a2b8!important}.border-warning{border-color:#edaa16!important}.border-danger{border-color:#dc3545!important}.border-light{border-color:#f8f9fa!important}.border-dark{border-color:#212529!important}.border-white{border-color:#fff!important}.border-1{border-width:1px!important}.border-2{border-width:2px!important}.border-3{border-width:3px!important}.border-4{border-width:4px!important}.border-5{border-width:5px!important}.w-25{width:25%!important}.w-50{width:50%!important}.w-75{width:75%!important}.w-100{width:100%!important}.w-auto{width:auto!important}.mw-100{max-width:100%!important}.vw-100{width:100vw!important}.min-vw-100{min-width:100vw!important}.h-25{height:25%!important}.h-50{height:50%!important}.h-75{height:75%!important}.h-100{height:100%!important}.h-auto{height:auto!important}.mh-100{max-height:100%!important}.vh-100{height:100vh!important}.min-vh-100{min-height:100vh!important}.flex-fill{flex:1 1 auto!important}.flex-row{flex-direction:row!important}.flex-column{flex-direction:column!important}.flex-row-reverse{flex-direction:row-reverse!important}.flex-column-reverse{flex-direction:column-reverse!important}.flex-grow-0{flex-grow:0!important}.flex-grow-1{flex-grow:1!important}.flex-shrink-0{flex-shrink:0!important}.flex-shrink-1{flex-shrink:1!important}.flex-wrap{flex-wrap:wrap!important}.flex-nowrap{flex-wrap:nowrap!important}.flex-wrap-reverse{flex-wrap:wrap-reverse!important}.gap-0{gap:0!important}.gap-1{gap:.25rem!important}.gap-2{gap:.5rem!important}.gap-3{gap:1rem!important}.gap-4{gap:1.5rem!important}.gap-5{gap:3rem!important}.justify-content-start{justify-content:flex-start!important}.justify-content-end{justify-content:flex-end!important}.justify-content-center{justify-content:center!important}.justify-content-between{justify-content:space-between!important}.justify-content-around{justify-content:space-around!important}.justify-content-evenly{justify-content:space-evenly!important}.align-items-start{align-items:flex-start!important}.align-items-end{align-items:flex-end!important}.align-items-center{align-items:center!important}.align-items-baseline{align-items:baseline!important}.align-items-stretch{align-items:stretch!important}.align-content-start{align-content:flex-start!important}.align-content-end{align-content:flex-end!important}.align-content-center{align-content:center!important}.align-content-between{align-content:space-between!important}.align-content-around{align-content:space-around!important}.align-content-stretch{align-content:stretch!important}.align-self-auto{align-self:auto!important}.align-self-start{align-self:flex-start!important}.align-self-end{align-self:flex-end!important}.align-self-center{align-self:center!important}.align-self-baseline{align-self:baseline!important}.align-self-stretch{align-self:stretch!important}.order-first{order:-1!important}.order-0{order:0!important}.order-1{order:1!important}.order-2{order:2!important}.order-3{order:3!important}.order-4{order:4!important}.order-5{order:5!important}.order-last{order:6!important}.m-0{margin:0!important}.m-1{margin:.25rem!important}.m-2{margin:.5rem!important}.m-3{margin:1rem!important}.m-4{margin:1.5rem!important}.m-5{margin:3rem!important}.m-auto{margin:auto!important}.mx-0{margin-right:0!important;margin-left:0!important}.mx-1{margin-right:.25rem!important;margin-left:.25rem!important}.mx-2{margin-right:.5rem!important;margin-left:.5rem!important}.mx-3{margin-right:1rem!important;margin-left:1rem!important}.mx-4{margin-right:1.5rem!important;margin-left:1.5rem!important}.mx-5{margin-right:3rem!important;margin-left:3rem!important}.mx-auto{margin-right:auto!important;margin-left:auto!important}.my-0{margin-top:0!important;margin-bottom:0!important}.my-1{margin-top:.25rem!important;margin-bottom:.25rem!important}.my-2{margin-top:.5rem!important;margin-bottom:.5rem!important}.my-3{margin-top:1rem!important;margin-bottom:1rem!important}.my-4{margin-top:1.5rem!important;margin-bottom:1.5rem!important}.my-5{margin-top:3rem!important;margin-bottom:3rem!important}.my-auto{margin-top:auto!important;margin-bottom:auto!important}.mt-0{margin-top:0!important}.mt-1{margin-top:.25rem!important}.mt-2{margin-top:.5rem!important}.mt-3{margin-top:1rem!important}.mt-4{margin-top:1.5rem!important}.mt-5{margin-top:3rem!important}.mt-auto{margin-top:auto!important}.me-0{margin-right:0!important}.me-1{margin-right:.25rem!important}.me-2{margin-right:.5rem!important}.me-3{margin-right:1rem!important}.me-4{margin-right:1.5rem!important}.me-5{margin-right:3rem!important}.me-auto{margin-right:auto!important}.mb-0{margin-bottom:0!important}.mb-1{margin-bottom:.25rem!important}.mb-2{margin-bottom:.5rem!important}.mb-3{margin-bottom:1rem!important}.mb-4{margin-bottom:1.5rem!important}.mb-5{margin-bottom:3rem!important}.mb-auto{margin-bottom:auto!important}.ms-0{margin-left:0!important}.ms-1{margin-left:.25rem!important}.ms-2{margin-left:.5rem!important}.ms-3{margin-left:1rem!important}.ms-4{margin-left:1.5rem!important}.ms-5{margin-left:3rem!important}.ms-auto{margin-left:auto!important}.p-0{padding:0!important}.p-1{padding:.25rem!important}.p-2{padding:.5rem!important}.p-3{padding:1rem!important}.p-4{padding:1.5rem!important}.p-5{padding:3rem!important}.px-0{padding-right:0!important;padding-left:0!important}.px-1{padding-right:.25rem!important;padding-left:.25rem!important}.px-2{padding-right:.5rem!important;padding-left:.5rem!important}.px-3{padding-right:1rem!important;padding-left:1rem!important}.px-4{padding-right:1.5rem!important;padding-left:1.5rem!important}.px-5{padding-right:3rem!important;padding-left:3rem!important}.py-0{padding-top:0!important;padding-bottom:0!important}.py-1{padding-top:.25rem!important;padding-bottom:.25rem!important}.py-2{padding-top:.5rem!important;padding-bottom:.5rem!important}.py-3{padding-top:1rem!important;padding-bottom:1rem!important}.py-4{padding-top:1.5rem!important;padding-bottom:1.5rem!important}.py-5{padding-top:3rem!important;padding-bottom:3rem!important}.pt-0{padding-top:0!important}.pt-1{padding-top:.25rem!important}.pt-2{padding-top:.5rem!important}.pt-3{padding-top:1rem!important}.pt-4{padding-top:1.5rem!important}.pt-5{padding-top:3rem!important}.pe-0{padding-right:0!important}.pe-1{padding-right:.25rem!important}.pe-2{padding-right:.5rem!important}.pe-3{padding-right:1rem!important}.pe-4{padding-right:1.5rem!important}.pe-5{padding-right:3rem!important}.pb-0{padding-bottom:0!important}.pb-1{padding-bottom:.25rem!important}.pb-2{padding-bottom:.5rem!important}.pb-3{padding-bottom:1rem!important}.pb-4{padding-bottom:1.5rem!important}.pb-5{padding-bottom:3rem!important}.ps-0{padding-left:0!important}.ps-1{padding-left:.25rem!important}.ps-2{padding-left:.5rem!important}.ps-3{padding-left:1rem!important}.ps-4{padding-left:1.5rem!important}.ps-5{padding-left:3rem!important}.font-monospace{font-family:var(--bs-font-monospace)!important}.fs-1{font-size:calc(1.375rem + 1.5vw)!important}.fs-2{font-size:calc(1.325rem + .9vw)!important}.fs-3{font-size:calc(1.3rem + .6vw)!important}.fs-4{font-size:calc(1.275rem + .3vw)!important}.fs-5{font-size:1.25rem!important}.fs-6{font-size:1rem!important}.fst-italic{font-style:italic!important}.fst-normal{font-style:normal!important}.fw-light{font-weight:300!important}.fw-lighter{font-weight:lighter!important}.fw-normal{font-weight:400!important}.fw-bold{font-weight:700!important}.fw-bolder{font-weight:bolder!important}.lh-1{line-height:1!important}.lh-sm{line-height:1.25!important}.lh-base{line-height:1.5!important}.lh-lg{line-height:2!important}.text-start{text-align:left!important}.text-end{text-align:right!important}.text-center{text-align:center!important}.text-decoration-none{text-decoration:none!important}.text-decoration-underline{text-decoration:underline!important}.text-decoration-line-through{text-decoration:line-through!important}.text-lowercase{text-transform:lowercase!important}.text-uppercase{text-transform:uppercase!important}.text-capitalize{text-transform:capitalize!important}.text-wrap{white-space:normal!important}.text-nowrap{white-space:nowrap!important}.text-break{word-wrap:break-word!important;word-break:break-word!important}.text-primary{--bs-text-opacity:1;color:rgba(var(--bs-primary-rgb),var(--bs-text-opacity))!important}.text-secondary{--bs-text-opacity:1;color:rgba(var(--bs-secondary-rgb),var(--bs-text-opacity))!important}.text-success{--bs-text-opacity:1;color:rgba(var(--bs-success-rgb),var(--bs-text-opacity))!important}.text-info{--bs-text-opacity:1;color:rgba(var(--bs-info-rgb),var(--bs-text-opacity))!important}.text-warning{--bs-text-opacity:1;color:rgba(var(--bs-warning-rgb),var(--bs-text-opacity))!important}.text-danger{--bs-text-opacity:1;color:rgba(var(--bs-danger-rgb),var(--bs-text-opacity))!important}.text-light{--bs-text-opacity:1;color:rgba(var(--bs-light-rgb),var(--bs-text-opacity))!important}.text-dark{--bs-text-opacity:1;color:rgba(var(--bs-dark-rgb),var(--bs-text-opacity))!important}.text-black{--bs-text-opacity:1;color:rgba(var(--bs-black-rgb),var(--bs-text-opacity))!important}.text-white{--bs-text-opacity:1;color:rgba(var(--bs-white-rgb),var(--bs-text-opacity))!important}.text-body{--bs-text-opacity:1;color:rgba(var(--bs-body-color-rgb),var(--bs-text-opacity))!important}.text-muted{--bs-text-opacity:1;color:#6c757d!important}.text-black-50{--bs-text-opacity:1;color:rgba(0,0,0,.5)!important}.text-white-50{--bs-text-opacity:1;color:rgba(255,255,255,.5)!important}.text-reset{--bs-text-opacity:1;color:inherit!important}.text-opacity-25{--bs-text-opacity:0.25}.text-opacity-50{--bs-text-opacity:0.5}.text-opacity-75{--bs-text-opacity:0.75}.text-opacity-100{--bs-text-opacity:1}.bg-primary{--bs-bg-opacity:1;background-color:rgba(var(--bs-primary-rgb),var(--bs-bg-opacity))!important}.bg-secondary{--bs-bg-opacity:1;background-color:rgba(var(--bs-secondary-rgb),var(--bs-bg-opacity))!important}.bg-success{--bs-bg-opacity:1;background-color:rgba(var(--bs-success-rgb),var(--bs-bg-opacity))!important}.bg-info{--bs-bg-opacity:1;background-color:rgba(var(--bs-info-rgb),var(--bs-bg-opacity))!important}.bg-warning{--bs-bg-opacity:1;background-color:rgba(var(--bs-warning-rgb),var(--bs-bg-opacity))!important}.bg-danger{--bs-bg-opacity:1;background-color:rgba(var(--bs-danger-rgb),var(--bs-bg-opacity))!important}.bg-light{--bs-bg-opacity:1;background-color:rgba(var(--bs-light-rgb),var(--bs-bg-opacity))!important}.bg-dark{--bs-bg-opacity:1;background-color:rgba(var(--bs-dark-rgb),var(--bs-bg-opacity))!important}.bg-black{--bs-bg-opacity:1;background-color:rgba(var(--bs-black-rgb),var(--bs-bg-opacity))!important}.bg-white{--bs-bg-opacity:1;background-color:rgba(var(--bs-white-rgb),var(--bs-bg-opacity))!important}.bg-body{--bs-bg-opacity:1;background-color:rgba(var(--bs-body-bg-rgb),var(--bs-bg-opacity))!important}.bg-transparent{--bs-bg-opacity:1;background-color:transparent!important}.bg-opacity-10{--bs-bg-opacity:0.1}.bg-opacity-25{--bs-bg-opacity:0.25}.bg-opacity-50{--bs-bg-opacity:0.5}.bg-opacity-75{--bs-bg-opacity:0.75}.bg-opacity-100{--bs-bg-opacity:1}.bg-gradient{background-image:var(--bs-gradient)!important}.user-select-all{-webkit-user-select:all!important;-moz-user-select:all!important;user-select:all!important}.user-select-auto{-webkit-user-select:auto!important;-moz-user-select:auto!important;user-select:auto!important}.user-select-none{-webkit-user-select:none!important;-moz-user-select:none!important;user-select:none!important}.pe-none{pointer-events:none!important}.pe-auto{pointer-events:auto!important}.rounded{border-radius:.25rem!important}.rounded-0{border-radius:0!important}.rounded-1{border-radius:.2rem!important}.rounded-2{border-radius:.25rem!important}.rounded-3{border-radius:.3rem!important}.rounded-circle{border-radius:50%!important}.rounded-pill{border-radius:50rem!important}.rounded-top{border-top-left-radius:.25rem!important;border-top-right-radius:.25rem!important}.rounded-end{border-top-right-radius:.25rem!important;border-bottom-right-radius:.25rem!important}.rounded-bottom{border-bottom-right-radius:.25rem!important;border-bottom-left-radius:.25rem!important}.rounded-start{border-bottom-left-radius:.25rem!important;border-top-left-radius:.25rem!important}.visible{visibility:visible!important}.invisible{visibility:hidden!important}@media (min-width:576px){.float-sm-start{float:left!important}.float-sm-end{float:right!important}.float-sm-none{float:none!important}.d-sm-inline{display:inline!important}.d-sm-inline-block{display:inline-block!important}.d-sm-block{display:block!important}.d-sm-grid{display:grid!important}.d-sm-table{display:table!important}.d-sm-table-row{display:table-row!important}.d-sm-table-cell{display:table-cell!important}.d-sm-flex{display:flex!important}.d-sm-inline-flex{display:inline-flex!important}.d-sm-none{display:none!important}.flex-sm-fill{flex:1 1 auto!important}.flex-sm-row{flex-direction:row!important}.flex-sm-column{flex-direction:column!important}.flex-sm-row-reverse{flex-direction:row-reverse!important}.flex-sm-column-reverse{flex-direction:column-reverse!important}.flex-sm-grow-0{flex-grow:0!important}.flex-sm-grow-1{flex-grow:1!important}.flex-sm-shrink-0{flex-shrink:0!important}.flex-sm-shrink-1{flex-shrink:1!important}.flex-sm-wrap{flex-wrap:wrap!important}.flex-sm-nowrap{flex-wrap:nowrap!important}.flex-sm-wrap-reverse{flex-wrap:wrap-reverse!important}.gap-sm-0{gap:0!important}.gap-sm-1{gap:.25rem!important}.gap-sm-2{gap:.5rem!important}.gap-sm-3{gap:1rem!important}.gap-sm-4{gap:1.5rem!important}.gap-sm-5{gap:3rem!important}.justify-content-sm-start{justify-content:flex-start!important}.justify-content-sm-end{justify-content:flex-end!important}.justify-content-sm-center{justify-content:center!important}.justify-content-sm-between{justify-content:space-between!important}.justify-content-sm-around{justify-content:space-around!important}.justify-content-sm-evenly{justify-content:space-evenly!important}.align-items-sm-start{align-items:flex-start!important}.align-items-sm-end{align-items:flex-end!important}.align-items-sm-center{align-items:center!important}.align-items-sm-baseline{align-items:baseline!important}.align-items-sm-stretch{align-items:stretch!important}.align-content-sm-start{align-content:flex-start!important}.align-content-sm-end{align-content:flex-end!important}.align-content-sm-center{align-content:center!important}.align-content-sm-between{align-content:space-between!important}.align-content-sm-around{align-content:space-around!important}.align-content-sm-stretch{align-content:stretch!important}.align-self-sm-auto{align-self:auto!important}.align-self-sm-start{align-self:flex-start!important}.align-self-sm-end{align-self:flex-end!important}.align-self-sm-center{align-self:center!important}.align-self-sm-baseline{align-self:baseline!important}.align-self-sm-stretch{align-self:stretch!important}.order-sm-first{order:-1!important}.order-sm-0{order:0!important}.order-sm-1{order:1!important}.order-sm-2{order:2!important}.order-sm-3{order:3!important}.order-sm-4{order:4!important}.order-sm-5{order:5!important}.order-sm-last{order:6!important}.m-sm-0{margin:0!important}.m-sm-1{margin:.25rem!important}.m-sm-2{margin:.5rem!important}.m-sm-3{margin:1rem!important}.m-sm-4{margin:1.5rem!important}.m-sm-5{margin:3rem!important}.m-sm-auto{margin:auto!important}.mx-sm-0{margin-right:0!important;margin-left:0!important}.mx-sm-1{margin-right:.25rem!important;margin-left:.25rem!important}.mx-sm-2{margin-right:.5rem!important;margin-left:.5rem!important}.mx-sm-3{margin-right:1rem!important;margin-left:1rem!important}.mx-sm-4{margin-right:1.5rem!important;margin-left:1.5rem!important}.mx-sm-5{margin-right:3rem!important;margin-left:3rem!important}.mx-sm-auto{margin-right:auto!important;margin-left:auto!important}.my-sm-0{margin-top:0!important;margin-bottom:0!important}.my-sm-1{margin-top:.25rem!important;margin-bottom:.25rem!important}.my-sm-2{margin-top:.5rem!important;margin-bottom:.5rem!important}.my-sm-3{margin-top:1rem!important;margin-bottom:1rem!important}.my-sm-4{margin-top:1.5rem!important;margin-bottom:1.5rem!important}.my-sm-5{margin-top:3rem!important;margin-bottom:3rem!important}.my-sm-auto{margin-top:auto!important;margin-bottom:auto!important}.mt-sm-0{margin-top:0!important}.mt-sm-1{margin-top:.25rem!important}.mt-sm-2{margin-top:.5rem!important}.mt-sm-3{margin-top:1rem!important}.mt-sm-4{margin-top:1.5rem!important}.mt-sm-5{margin-top:3rem!important}.mt-sm-auto{margin-top:auto!important}.me-sm-0{margin-right:0!important}.me-sm-1{margin-right:.25rem!important}.me-sm-2{margin-right:.5rem!important}.me-sm-3{margin-right:1rem!important}.me-sm-4{margin-right:1.5rem!important}.me-sm-5{margin-right:3rem!important}.me-sm-auto{margin-right:auto!important}.mb-sm-0{margin-bottom:0!important}.mb-sm-1{margin-bottom:.25rem!important}.mb-sm-2{margin-bottom:.5rem!important}.mb-sm-3{margin-bottom:1rem!important}.mb-sm-4{margin-bottom:1.5rem!important}.mb-sm-5{margin-bottom:3rem!important}.mb-sm-auto{margin-bottom:auto!important}.ms-sm-0{margin-left:0!important}.ms-sm-1{margin-left:.25rem!important}.ms-sm-2{margin-left:.5rem!important}.ms-sm-3{margin-left:1rem!important}.ms-sm-4{margin-left:1.5rem!important}.ms-sm-5{margin-left:3rem!important}.ms-sm-auto{margin-left:auto!important}.p-sm-0{padding:0!important}.p-sm-1{padding:.25rem!important}.p-sm-2{padding:.5rem!important}.p-sm-3{padding:1rem!important}.p-sm-4{padding:1.5rem!important}.p-sm-5{padding:3rem!important}.px-sm-0{padding-right:0!important;padding-left:0!important}.px-sm-1{padding-right:.25rem!important;padding-left:.25rem!important}.px-sm-2{padding-right:.5rem!important;padding-left:.5rem!important}.px-sm-3{padding-right:1rem!important;padding-left:1rem!important}.px-sm-4{padding-right:1.5rem!important;padding-left:1.5rem!important}.px-sm-5{padding-right:3rem!important;padding-left:3rem!important}.py-sm-0{padding-top:0!important;padding-bottom:0!important}.py-sm-1{padding-top:.25rem!important;padding-bottom:.25rem!important}.py-sm-2{padding-top:.5rem!important;padding-bottom:.5rem!important}.py-sm-3{padding-top:1rem!important;padding-bottom:1rem!important}.py-sm-4{padding-top:1.5rem!important;padding-bottom:1.5rem!important}.py-sm-5{padding-top:3rem!important;padding-bottom:3rem!important}.pt-sm-0{padding-top:0!important}.pt-sm-1{padding-top:.25rem!important}.pt-sm-2{padding-top:.5rem!important}.pt-sm-3{padding-top:1rem!important}.pt-sm-4{padding-top:1.5rem!important}.pt-sm-5{padding-top:3rem!important}.pe-sm-0{padding-right:0!important}.pe-sm-1{padding-right:.25rem!important}.pe-sm-2{padding-right:.5rem!important}.pe-sm-3{padding-right:1rem!important}.pe-sm-4{padding-right:1.5rem!important}.pe-sm-5{padding-right:3rem!important}.pb-sm-0{padding-bottom:0!important}.pb-sm-1{padding-bottom:.25rem!important}.pb-sm-2{padding-bottom:.5rem!important}.pb-sm-3{padding-bottom:1rem!important}.pb-sm-4{padding-bottom:1.5rem!important}.pb-sm-5{padding-bottom:3rem!important}.ps-sm-0{padding-left:0!important}.ps-sm-1{padding-left:.25rem!important}.ps-sm-2{padding-left:.5rem!important}.ps-sm-3{padding-left:1rem!important}.ps-sm-4{padding-left:1.5rem!important}.ps-sm-5{padding-left:3rem!important}.text-sm-start{text-align:left!important}.text-sm-end{text-align:right!important}.text-sm-center{text-align:center!important}}@media (min-width:768px){.float-md-start{float:left!important}.float-md-end{float:right!important}.float-md-none{float:none!important}.d-md-inline{display:inline!important}.d-md-inline-block{display:inline-block!important}.d-md-block{display:block!important}.d-md-grid{display:grid!important}.d-md-table{display:table!important}.d-md-table-row{display:table-row!important}.d-md-table-cell{display:table-cell!important}.d-md-flex{display:flex!important}.d-md-inline-flex{display:inline-flex!important}.d-md-none{display:none!important}.flex-md-fill{flex:1 1 auto!important}.flex-md-row{flex-direction:row!important}.flex-md-column{flex-direction:column!important}.flex-md-row-reverse{flex-direction:row-reverse!important}.flex-md-column-reverse{flex-direction:column-reverse!important}.flex-md-grow-0{flex-grow:0!important}.flex-md-grow-1{flex-grow:1!important}.flex-md-shrink-0{flex-shrink:0!important}.flex-md-shrink-1{flex-shrink:1!important}.flex-md-wrap{flex-wrap:wrap!important}.flex-md-nowrap{flex-wrap:nowrap!important}.flex-md-wrap-reverse{flex-wrap:wrap-reverse!important}.gap-md-0{gap:0!important}.gap-md-1{gap:.25rem!important}.gap-md-2{gap:.5rem!important}.gap-md-3{gap:1rem!important}.gap-md-4{gap:1.5rem!important}.gap-md-5{gap:3rem!important}.justify-content-md-start{justify-content:flex-start!important}.justify-content-md-end{justify-content:flex-end!important}.justify-content-md-center{justify-content:center!important}.justify-content-md-between{justify-content:space-between!important}.justify-content-md-around{justify-content:space-around!important}.justify-content-md-evenly{justify-content:space-evenly!important}.align-items-md-start{align-items:flex-start!important}.align-items-md-end{align-items:flex-end!important}.align-items-md-center{align-items:center!important}.align-items-md-baseline{align-items:baseline!important}.align-items-md-stretch{align-items:stretch!important}.align-content-md-start{align-content:flex-start!important}.align-content-md-end{align-content:flex-end!important}.align-content-md-center{align-content:center!important}.align-content-md-between{align-content:space-between!important}.align-content-md-around{align-content:space-around!important}.align-content-md-stretch{align-content:stretch!important}.align-self-md-auto{align-self:auto!important}.align-self-md-start{align-self:flex-start!important}.align-self-md-end{align-self:flex-end!important}.align-self-md-center{align-self:center!important}.align-self-md-baseline{align-self:baseline!important}.align-self-md-stretch{align-self:stretch!important}.order-md-first{order:-1!important}.order-md-0{order:0!important}.order-md-1{order:1!important}.order-md-2{order:2!important}.order-md-3{order:3!important}.order-md-4{order:4!important}.order-md-5{order:5!important}.order-md-last{order:6!important}.m-md-0{margin:0!important}.m-md-1{margin:.25rem!important}.m-md-2{margin:.5rem!important}.m-md-3{margin:1rem!important}.m-md-4{margin:1.5rem!important}.m-md-5{margin:3rem!important}.m-md-auto{margin:auto!important}.mx-md-0{margin-right:0!important;margin-left:0!important}.mx-md-1{margin-right:.25rem!important;margin-left:.25rem!important}.mx-md-2{margin-right:.5rem!important;margin-left:.5rem!important}.mx-md-3{margin-right:1rem!important;margin-left:1rem!important}.mx-md-4{margin-right:1.5rem!important;margin-left:1.5rem!important}.mx-md-5{margin-right:3rem!important;margin-left:3rem!important}.mx-md-auto{margin-right:auto!important;margin-left:auto!important}.my-md-0{margin-top:0!important;margin-bottom:0!important}.my-md-1{margin-top:.25rem!important;margin-bottom:.25rem!important}.my-md-2{margin-top:.5rem!important;margin-bottom:.5rem!important}.my-md-3{margin-top:1rem!important;margin-bottom:1rem!important}.my-md-4{margin-top:1.5rem!important;margin-bottom:1.5rem!important}.my-md-5{margin-top:3rem!important;margin-bottom:3rem!important}.my-md-auto{margin-top:auto!important;margin-bottom:auto!important}.mt-md-0{margin-top:0!important}.mt-md-1{margin-top:.25rem!important}.mt-md-2{margin-top:.5rem!important}.mt-md-3{margin-top:1rem!important}.mt-md-4{margin-top:1.5rem!important}.mt-md-5{margin-top:3rem!important}.mt-md-auto{margin-top:auto!important}.me-md-0{margin-right:0!important}.me-md-1{margin-right:.25rem!important}.me-md-2{margin-right:.5rem!important}.me-md-3{margin-right:1rem!important}.me-md-4{margin-right:1.5rem!important}.me-md-5{margin-right:3rem!important}.me-md-auto{margin-right:auto!important}.mb-md-0{margin-bottom:0!important}.mb-md-1{margin-bottom:.25rem!important}.mb-md-2{margin-bottom:.5rem!important}.mb-md-3{margin-bottom:1rem!important}.mb-md-4{margin-bottom:1.5rem!important}.mb-md-5{margin-bottom:3rem!important}.mb-md-auto{margin-bottom:auto!important}.ms-md-0{margin-left:0!important}.ms-md-1{margin-left:.25rem!important}.ms-md-2{margin-left:.5rem!important}.ms-md-3{margin-left:1rem!important}.ms-md-4{margin-left:1.5rem!important}.ms-md-5{margin-left:3rem!important}.ms-md-auto{margin-left:auto!important}.p-md-0{padding:0!important}.p-md-1{padding:.25rem!important}.p-md-2{padding:.5rem!important}.p-md-3{padding:1rem!important}.p-md-4{padding:1.5rem!important}.p-md-5{padding:3rem!important}.px-md-0{padding-right:0!important;padding-left:0!important}.px-md-1{padding-right:.25rem!important;padding-left:.25rem!important}.px-md-2{padding-right:.5rem!important;padding-left:.5rem!important}.px-md-3{padding-right:1rem!important;padding-left:1rem!important}.px-md-4{padding-right:1.5rem!important;padding-left:1.5rem!important}.px-md-5{padding-right:3rem!important;padding-left:3rem!important}.py-md-0{padding-top:0!important;padding-bottom:0!important}.py-md-1{padding-top:.25rem!important;padding-bottom:.25rem!important}.py-md-2{padding-top:.5rem!important;padding-bottom:.5rem!important}.py-md-3{padding-top:1rem!important;padding-bottom:1rem!important}.py-md-4{padding-top:1.5rem!important;padding-bottom:1.5rem!important}.py-md-5{padding-top:3rem!important;padding-bottom:3rem!important}.pt-md-0{padding-top:0!important}.pt-md-1{padding-top:.25rem!important}.pt-md-2{padding-top:.5rem!important}.pt-md-3{padding-top:1rem!important}.pt-md-4{padding-top:1.5rem!important}.pt-md-5{padding-top:3rem!important}.pe-md-0{padding-right:0!important}.pe-md-1{padding-right:.25rem!important}.pe-md-2{padding-right:.5rem!important}.pe-md-3{padding-right:1rem!important}.pe-md-4{padding-right:1.5rem!important}.pe-md-5{padding-right:3rem!important}.pb-md-0{padding-bottom:0!important}.pb-md-1{padding-bottom:.25rem!important}.pb-md-2{padding-bottom:.5rem!important}.pb-md-3{padding-bottom:1rem!important}.pb-md-4{padding-bottom:1.5rem!important}.pb-md-5{padding-bottom:3rem!important}.ps-md-0{padding-left:0!important}.ps-md-1{padding-left:.25rem!important}.ps-md-2{padding-left:.5rem!important}.ps-md-3{padding-left:1rem!important}.ps-md-4{padding-left:1.5rem!important}.ps-md-5{padding-left:3rem!important}.text-md-start{text-align:left!important}.text-md-end{text-align:right!important}.text-md-center{text-align:center!important}}@media (min-width:992px){.float-lg-start{float:left!important}.float-lg-end{float:right!important}.float-lg-none{float:none!important}.d-lg-inline{display:inline!important}.d-lg-inline-block{display:inline-block!important}.d-lg-block{display:block!important}.d-lg-grid{display:grid!important}.d-lg-table{display:table!important}.d-lg-table-row{display:table-row!important}.d-lg-table-cell{display:table-cell!important}.d-lg-flex{display:flex!important}.d-lg-inline-flex{display:inline-flex!important}.d-lg-none{display:none!important}.flex-lg-fill{flex:1 1 auto!important}.flex-lg-row{flex-direction:row!important}.flex-lg-column{flex-direction:column!important}.flex-lg-row-reverse{flex-direction:row-reverse!important}.flex-lg-column-reverse{flex-direction:column-reverse!important}.flex-lg-grow-0{flex-grow:0!important}.flex-lg-grow-1{flex-grow:1!important}.flex-lg-shrink-0{flex-shrink:0!important}.flex-lg-shrink-1{flex-shrink:1!important}.flex-lg-wrap{flex-wrap:wrap!important}.flex-lg-nowrap{flex-wrap:nowrap!important}.flex-lg-wrap-reverse{flex-wrap:wrap-reverse!important}.gap-lg-0{gap:0!important}.gap-lg-1{gap:.25rem!important}.gap-lg-2{gap:.5rem!important}.gap-lg-3{gap:1rem!important}.gap-lg-4{gap:1.5rem!important}.gap-lg-5{gap:3rem!important}.justify-content-lg-start{justify-content:flex-start!important}.justify-content-lg-end{justify-content:flex-end!important}.justify-content-lg-center{justify-content:center!important}.justify-content-lg-between{justify-content:space-between!important}.justify-content-lg-around{justify-content:space-around!important}.justify-content-lg-evenly{justify-content:space-evenly!important}.align-items-lg-start{align-items:flex-start!important}.align-items-lg-end{align-items:flex-end!important}.align-items-lg-center{align-items:center!important}.align-items-lg-baseline{align-items:baseline!important}.align-items-lg-stretch{align-items:stretch!important}.align-content-lg-start{align-content:flex-start!important}.align-content-lg-end{align-content:flex-end!important}.align-content-lg-center{align-content:center!important}.align-content-lg-between{align-content:space-between!important}.align-content-lg-around{align-content:space-around!important}.align-content-lg-stretch{align-content:stretch!important}.align-self-lg-auto{align-self:auto!important}.align-self-lg-start{align-self:flex-start!important}.align-self-lg-end{align-self:flex-end!important}.align-self-lg-center{align-self:center!important}.align-self-lg-baseline{align-self:baseline!important}.align-self-lg-stretch{align-self:stretch!important}.order-lg-first{order:-1!important}.order-lg-0{order:0!important}.order-lg-1{order:1!important}.order-lg-2{order:2!important}.order-lg-3{order:3!important}.order-lg-4{order:4!important}.order-lg-5{order:5!important}.order-lg-last{order:6!important}.m-lg-0{margin:0!important}.m-lg-1{margin:.25rem!important}.m-lg-2{margin:.5rem!important}.m-lg-3{margin:1rem!important}.m-lg-4{margin:1.5rem!important}.m-lg-5{margin:3rem!important}.m-lg-auto{margin:auto!important}.mx-lg-0{margin-right:0!important;margin-left:0!important}.mx-lg-1{margin-right:.25rem!important;margin-left:.25rem!important}.mx-lg-2{margin-right:.5rem!important;margin-left:.5rem!important}.mx-lg-3{margin-right:1rem!important;margin-left:1rem!important}.mx-lg-4{margin-right:1.5rem!important;margin-left:1.5rem!important}.mx-lg-5{margin-right:3rem!important;margin-left:3rem!important}.mx-lg-auto{margin-right:auto!important;margin-left:auto!important}.my-lg-0{margin-top:0!important;margin-bottom:0!important}.my-lg-1{margin-top:.25rem!important;margin-bottom:.25rem!important}.my-lg-2{margin-top:.5rem!important;margin-bottom:.5rem!important}.my-lg-3{margin-top:1rem!important;margin-bottom:1rem!important}.my-lg-4{margin-top:1.5rem!important;margin-bottom:1.5rem!important}.my-lg-5{margin-top:3rem!important;margin-bottom:3rem!important}.my-lg-auto{margin-top:auto!important;margin-bottom:auto!important}.mt-lg-0{margin-top:0!important}.mt-lg-1{margin-top:.25rem!important}.mt-lg-2{margin-top:.5rem!important}.mt-lg-3{margin-top:1rem!important}.mt-lg-4{margin-top:1.5rem!important}.mt-lg-5{margin-top:3rem!important}.mt-lg-auto{margin-top:auto!important}.me-lg-0{margin-right:0!important}.me-lg-1{margin-right:.25rem!important}.me-lg-2{margin-right:.5rem!important}.me-lg-3{margin-right:1rem!important}.me-lg-4{margin-right:1.5rem!important}.me-lg-5{margin-right:3rem!important}.me-lg-auto{margin-right:auto!important}.mb-lg-0{margin-bottom:0!important}.mb-lg-1{margin-bottom:.25rem!important}.mb-lg-2{margin-bottom:.5rem!important}.mb-lg-3{margin-bottom:1rem!important}.mb-lg-4{margin-bottom:1.5rem!important}.mb-lg-5{margin-bottom:3rem!important}.mb-lg-auto{margin-bottom:auto!important}.ms-lg-0{margin-left:0!important}.ms-lg-1{margin-left:.25rem!important}.ms-lg-2{margin-left:.5rem!important}.ms-lg-3{margin-left:1rem!important}.ms-lg-4{margin-left:1.5rem!important}.ms-lg-5{margin-left:3rem!important}.ms-lg-auto{margin-left:auto!important}.p-lg-0{padding:0!important}.p-lg-1{padding:.25rem!important}.p-lg-2{padding:.5rem!important}.p-lg-3{padding:1rem!important}.p-lg-4{padding:1.5rem!important}.p-lg-5{padding:3rem!important}.px-lg-0{padding-right:0!important;padding-left:0!important}.px-lg-1{padding-right:.25rem!important;padding-left:.25rem!important}.px-lg-2{padding-right:.5rem!important;padding-left:.5rem!important}.px-lg-3{padding-right:1rem!important;padding-left:1rem!important}.px-lg-4{padding-right:1.5rem!important;padding-left:1.5rem!important}.px-lg-5{padding-right:3rem!important;padding-left:3rem!important}.py-lg-0{padding-top:0!important;padding-bottom:0!important}.py-lg-1{padding-top:.25rem!important;padding-bottom:.25rem!important}.py-lg-2{padding-top:.5rem!important;padding-bottom:.5rem!important}.py-lg-3{padding-top:1rem!important;padding-bottom:1rem!important}.py-lg-4{padding-top:1.5rem!important;padding-bottom:1.5rem!important}.py-lg-5{padding-top:3rem!important;padding-bottom:3rem!important}.pt-lg-0{padding-top:0!important}.pt-lg-1{padding-top:.25rem!important}.pt-lg-2{padding-top:.5rem!important}.pt-lg-3{padding-top:1rem!important}.pt-lg-4{padding-top:1.5rem!important}.pt-lg-5{padding-top:3rem!important}.pe-lg-0{padding-right:0!important}.pe-lg-1{padding-right:.25rem!important}.pe-lg-2{padding-right:.5rem!important}.pe-lg-3{padding-right:1rem!important}.pe-lg-4{padding-right:1.5rem!important}.pe-lg-5{padding-right:3rem!important}.pb-lg-0{padding-bottom:0!important}.pb-lg-1{padding-bottom:.25rem!important}.pb-lg-2{padding-bottom:.5rem!important}.pb-lg-3{padding-bottom:1rem!important}.pb-lg-4{padding-bottom:1.5rem!important}.pb-lg-5{padding-bottom:3rem!important}.ps-lg-0{padding-left:0!important}.ps-lg-1{padding-left:.25rem!important}.ps-lg-2{padding-left:.5rem!important}.ps-lg-3{padding-left:1rem!important}.ps-lg-4{padding-left:1.5rem!important}.ps-lg-5{padding-left:3rem!important}.text-lg-start{text-align:left!important}.text-lg-end{text-align:right!important}.text-lg-center{text-align:center!important}}@media (min-width:1200px){.float-xl-start{float:left!important}.float-xl-end{float:right!important}.float-xl-none{float:none!important}.d-xl-inline{display:inline!important}.d-xl-inline-block{display:inline-block!important}.d-xl-block{display:block!important}.d-xl-grid{display:grid!important}.d-xl-table{display:table!important}.d-xl-table-row{display:table-row!important}.d-xl-table-cell{display:table-cell!important}.d-xl-flex{display:flex!important}.d-xl-inline-flex{display:inline-flex!important}.d-xl-none{display:none!important}.flex-xl-fill{flex:1 1 auto!important}.flex-xl-row{flex-direction:row!important}.flex-xl-column{flex-direction:column!important}.flex-xl-row-reverse{flex-direction:row-reverse!important}.flex-xl-column-reverse{flex-direction:column-reverse!important}.flex-xl-grow-0{flex-grow:0!important}.flex-xl-grow-1{flex-grow:1!important}.flex-xl-shrink-0{flex-shrink:0!important}.flex-xl-shrink-1{flex-shrink:1!important}.flex-xl-wrap{flex-wrap:wrap!important}.flex-xl-nowrap{flex-wrap:nowrap!important}.flex-xl-wrap-reverse{flex-wrap:wrap-reverse!important}.gap-xl-0{gap:0!important}.gap-xl-1{gap:.25rem!important}.gap-xl-2{gap:.5rem!important}.gap-xl-3{gap:1rem!important}.gap-xl-4{gap:1.5rem!important}.gap-xl-5{gap:3rem!important}.justify-content-xl-start{justify-content:flex-start!important}.justify-content-xl-end{justify-content:flex-end!important}.justify-content-xl-center{justify-content:center!important}.justify-content-xl-between{justify-content:space-between!important}.justify-content-xl-around{justify-content:space-around!important}.justify-content-xl-evenly{justify-content:space-evenly!important}.align-items-xl-start{align-items:flex-start!important}.align-items-xl-end{align-items:flex-end!important}.align-items-xl-center{align-items:center!important}.align-items-xl-baseline{align-items:baseline!important}.align-items-xl-stretch{align-items:stretch!important}.align-content-xl-start{align-content:flex-start!important}.align-content-xl-end{align-content:flex-end!important}.align-content-xl-center{align-content:center!important}.align-content-xl-between{align-content:space-between!important}.align-content-xl-around{align-content:space-around!important}.align-content-xl-stretch{align-content:stretch!important}.align-self-xl-auto{align-self:auto!important}.align-self-xl-start{align-self:flex-start!important}.align-self-xl-end{align-self:flex-end!important}.align-self-xl-center{align-self:center!important}.align-self-xl-baseline{align-self:baseline!important}.align-self-xl-stretch{align-self:stretch!important}.order-xl-first{order:-1!important}.order-xl-0{order:0!important}.order-xl-1{order:1!important}.order-xl-2{order:2!important}.order-xl-3{order:3!important}.order-xl-4{order:4!important}.order-xl-5{order:5!important}.order-xl-last{order:6!important}.m-xl-0{margin:0!important}.m-xl-1{margin:.25rem!important}.m-xl-2{margin:.5rem!important}.m-xl-3{margin:1rem!important}.m-xl-4{margin:1.5rem!important}.m-xl-5{margin:3rem!important}.m-xl-auto{margin:auto!important}.mx-xl-0{margin-right:0!important;margin-left:0!important}.mx-xl-1{margin-right:.25rem!important;margin-left:.25rem!important}.mx-xl-2{margin-right:.5rem!important;margin-left:.5rem!important}.mx-xl-3{margin-right:1rem!important;margin-left:1rem!important}.mx-xl-4{margin-right:1.5rem!important;margin-left:1.5rem!important}.mx-xl-5{margin-right:3rem!important;margin-left:3rem!important}.mx-xl-auto{margin-right:auto!important;margin-left:auto!important}.my-xl-0{margin-top:0!important;margin-bottom:0!important}.my-xl-1{margin-top:.25rem!important;margin-bottom:.25rem!important}.my-xl-2{margin-top:.5rem!important;margin-bottom:.5rem!important}.my-xl-3{margin-top:1rem!important;margin-bottom:1rem!important}.my-xl-4{margin-top:1.5rem!important;margin-bottom:1.5rem!important}.my-xl-5{margin-top:3rem!important;margin-bottom:3rem!important}.my-xl-auto{margin-top:auto!important;margin-bottom:auto!important}.mt-xl-0{margin-top:0!important}.mt-xl-1{margin-top:.25rem!important}.mt-xl-2{margin-top:.5rem!important}.mt-xl-3{margin-top:1rem!important}.mt-xl-4{margin-top:1.5rem!important}.mt-xl-5{margin-top:3rem!important}.mt-xl-auto{margin-top:auto!important}.me-xl-0{margin-right:0!important}.me-xl-1{margin-right:.25rem!important}.me-xl-2{margin-right:.5rem!important}.me-xl-3{margin-right:1rem!important}.me-xl-4{margin-right:1.5rem!important}.me-xl-5{margin-right:3rem!important}.me-xl-auto{margin-right:auto!important}.mb-xl-0{margin-bottom:0!important}.mb-xl-1{margin-bottom:.25rem!important}.mb-xl-2{margin-bottom:.5rem!important}.mb-xl-3{margin-bottom:1rem!important}.mb-xl-4{margin-bottom:1.5rem!important}.mb-xl-5{margin-bottom:3rem!important}.mb-xl-auto{margin-bottom:auto!important}.ms-xl-0{margin-left:0!important}.ms-xl-1{margin-left:.25rem!important}.ms-xl-2{margin-left:.5rem!important}.ms-xl-3{margin-left:1rem!important}.ms-xl-4{margin-left:1.5rem!important}.ms-xl-5{margin-left:3rem!important}.ms-xl-auto{margin-left:auto!important}.p-xl-0{padding:0!important}.p-xl-1{padding:.25rem!important}.p-xl-2{padding:.5rem!important}.p-xl-3{padding:1rem!important}.p-xl-4{padding:1.5rem!important}.p-xl-5{padding:3rem!important}.px-xl-0{padding-right:0!important;padding-left:0!important}.px-xl-1{padding-right:.25rem!important;padding-left:.25rem!important}.px-xl-2{padding-right:.5rem!important;padding-left:.5rem!important}.px-xl-3{padding-right:1rem!important;padding-left:1rem!important}.px-xl-4{padding-right:1.5rem!important;padding-left:1.5rem!important}.px-xl-5{padding-right:3rem!important;padding-left:3rem!important}.py-xl-0{padding-top:0!important;padding-bottom:0!important}.py-xl-1{padding-top:.25rem!important;padding-bottom:.25rem!important}.py-xl-2{padding-top:.5rem!important;padding-bottom:.5rem!important}.py-xl-3{padding-top:1rem!important;padding-bottom:1rem!important}.py-xl-4{padding-top:1.5rem!important;padding-bottom:1.5rem!important}.py-xl-5{padding-top:3rem!important;padding-bottom:3rem!important}.pt-xl-0{padding-top:0!important}.pt-xl-1{padding-top:.25rem!important}.pt-xl-2{padding-top:.5rem!important}.pt-xl-3{padding-top:1rem!important}.pt-xl-4{padding-top:1.5rem!important}.pt-xl-5{padding-top:3rem!important}.pe-xl-0{padding-right:0!important}.pe-xl-1{padding-right:.25rem!important}.pe-xl-2{padding-right:.5rem!important}.pe-xl-3{padding-right:1rem!important}.pe-xl-4{padding-right:1.5rem!important}.pe-xl-5{padding-right:3rem!important}.pb-xl-0{padding-bottom:0!important}.pb-xl-1{padding-bottom:.25rem!important}.pb-xl-2{padding-bottom:.5rem!important}.pb-xl-3{padding-bottom:1rem!important}.pb-xl-4{padding-bottom:1.5rem!important}.pb-xl-5{padding-bottom:3rem!important}.ps-xl-0{padding-left:0!important}.ps-xl-1{padding-left:.25rem!important}.ps-xl-2{padding-left:.5rem!important}.ps-xl-3{padding-left:1rem!important}.ps-xl-4{padding-left:1.5rem!important}.ps-xl-5{padding-left:3rem!important}.text-xl-start{text-align:left!important}.text-xl-end{text-align:right!important}.text-xl-center{text-align:center!important}}@media (min-width:1400px){.float-xxl-start{float:left!important}.float-xxl-end{float:right!important}.float-xxl-none{float:none!important}.d-xxl-inline{display:inline!important}.d-xxl-inline-block{display:inline-block!important}.d-xxl-block{display:block!important}.d-xxl-grid{display:grid!important}.d-xxl-table{display:table!important}.d-xxl-table-row{display:table-row!important}.d-xxl-table-cell{display:table-cell!important}.d-xxl-flex{display:flex!important}.d-xxl-inline-flex{display:inline-flex!important}.d-xxl-none{display:none!important}.flex-xxl-fill{flex:1 1 auto!important}.flex-xxl-row{flex-direction:row!important}.flex-xxl-column{flex-direction:column!important}.flex-xxl-row-reverse{flex-direction:row-reverse!important}.flex-xxl-column-reverse{flex-direction:column-reverse!important}.flex-xxl-grow-0{flex-grow:0!important}.flex-xxl-grow-1{flex-grow:1!important}.flex-xxl-shrink-0{flex-shrink:0!important}.flex-xxl-shrink-1{flex-shrink:1!important}.flex-xxl-wrap{flex-wrap:wrap!important}.flex-xxl-nowrap{flex-wrap:nowrap!important}.flex-xxl-wrap-reverse{flex-wrap:wrap-reverse!important}.gap-xxl-0{gap:0!important}.gap-xxl-1{gap:.25rem!important}.gap-xxl-2{gap:.5rem!important}.gap-xxl-3{gap:1rem!important}.gap-xxl-4{gap:1.5rem!important}.gap-xxl-5{gap:3rem!important}.justify-content-xxl-start{justify-content:flex-start!important}.justify-content-xxl-end{justify-content:flex-end!important}.justify-content-xxl-center{justify-content:center!important}.justify-content-xxl-between{justify-content:space-between!important}.justify-content-xxl-around{justify-content:space-around!important}.justify-content-xxl-evenly{justify-content:space-evenly!important}.align-items-xxl-start{align-items:flex-start!important}.align-items-xxl-end{align-items:flex-end!important}.align-items-xxl-center{align-items:center!important}.align-items-xxl-baseline{align-items:baseline!important}.align-items-xxl-stretch{align-items:stretch!important}.align-content-xxl-start{align-content:flex-start!important}.align-content-xxl-end{align-content:flex-end!important}.align-content-xxl-center{align-content:center!important}.align-content-xxl-between{align-content:space-between!important}.align-content-xxl-around{align-content:space-around!important}.align-content-xxl-stretch{align-content:stretch!important}.align-self-xxl-auto{align-self:auto!important}.align-self-xxl-start{align-self:flex-start!important}.align-self-xxl-end{align-self:flex-end!important}.align-self-xxl-center{align-self:center!important}.align-self-xxl-baseline{align-self:baseline!important}.align-self-xxl-stretch{align-self:stretch!important}.order-xxl-first{order:-1!important}.order-xxl-0{order:0!important}.order-xxl-1{order:1!important}.order-xxl-2{order:2!important}.order-xxl-3{order:3!important}.order-xxl-4{order:4!important}.order-xxl-5{order:5!important}.order-xxl-last{order:6!important}.m-xxl-0{margin:0!important}.m-xxl-1{margin:.25rem!important}.m-xxl-2{margin:.5rem!important}.m-xxl-3{margin:1rem!important}.m-xxl-4{margin:1.5rem!important}.m-xxl-5{margin:3rem!important}.m-xxl-auto{margin:auto!important}.mx-xxl-0{margin-right:0!important;margin-left:0!important}.mx-xxl-1{margin-right:.25rem!important;margin-left:.25rem!important}.mx-xxl-2{margin-right:.5rem!important;margin-left:.5rem!important}.mx-xxl-3{margin-right:1rem!important;margin-left:1rem!important}.mx-xxl-4{margin-right:1.5rem!important;margin-left:1.5rem!important}.mx-xxl-5{margin-right:3rem!important;margin-left:3rem!important}.mx-xxl-auto{margin-right:auto!important;margin-left:auto!important}.my-xxl-0{margin-top:0!important;margin-bottom:0!important}.my-xxl-1{margin-top:.25rem!important;margin-bottom:.25rem!important}.my-xxl-2{margin-top:.5rem!important;margin-bottom:.5rem!important}.my-xxl-3{margin-top:1rem!important;margin-bottom:1rem!important}.my-xxl-4{margin-top:1.5rem!important;margin-bottom:1.5rem!important}.my-xxl-5{margin-top:3rem!important;margin-bottom:3rem!important}.my-xxl-auto{margin-top:auto!important;margin-bottom:auto!important}.mt-xxl-0{margin-top:0!important}.mt-xxl-1{margin-top:.25rem!important}.mt-xxl-2{margin-top:.5rem!important}.mt-xxl-3{margin-top:1rem!important}.mt-xxl-4{margin-top:1.5rem!important}.mt-xxl-5{margin-top:3rem!important}.mt-xxl-auto{margin-top:auto!important}.me-xxl-0{margin-right:0!important}.me-xxl-1{margin-right:.25rem!important}.me-xxl-2{margin-right:.5rem!important}.me-xxl-3{margin-right:1rem!important}.me-xxl-4{margin-right:1.5rem!important}.me-xxl-5{margin-right:3rem!important}.me-xxl-auto{margin-right:auto!important}.mb-xxl-0{margin-bottom:0!important}.mb-xxl-1{margin-bottom:.25rem!important}.mb-xxl-2{margin-bottom:.5rem!important}.mb-xxl-3{margin-bottom:1rem!important}.mb-xxl-4{margin-bottom:1.5rem!important}.mb-xxl-5{margin-bottom:3rem!important}.mb-xxl-auto{margin-bottom:auto!important}.ms-xxl-0{margin-left:0!important}.ms-xxl-1{margin-left:.25rem!important}.ms-xxl-2{margin-left:.5rem!important}.ms-xxl-3{margin-left:1rem!important}.ms-xxl-4{margin-left:1.5rem!important}.ms-xxl-5{margin-left:3rem!important}.ms-xxl-auto{margin-left:auto!important}.p-xxl-0{padding:0!important}.p-xxl-1{padding:.25rem!important}.p-xxl-2{padding:.5rem!important}.p-xxl-3{padding:1rem!important}.p-xxl-4{padding:1.5rem!important}.p-xxl-5{padding:3rem!important}.px-xxl-0{padding-right:0!important;padding-left:0!important}.px-xxl-1{padding-right:.25rem!important;padding-left:.25rem!important}.px-xxl-2{padding-right:.5rem!important;padding-left:.5rem!important}.px-xxl-3{padding-right:1rem!important;padding-left:1rem!important}.px-xxl-4{padding-right:1.5rem!important;padding-left:1.5rem!important}.px-xxl-5{padding-right:3rem!important;padding-left:3rem!important}.py-xxl-0{padding-top:0!important;padding-bottom:0!important}.py-xxl-1{padding-top:.25rem!important;padding-bottom:.25rem!important}.py-xxl-2{padding-top:.5rem!important;padding-bottom:.5rem!important}.py-xxl-3{padding-top:1rem!important;padding-bottom:1rem!important}.py-xxl-4{padding-top:1.5rem!important;padding-bottom:1.5rem!important}.py-xxl-5{padding-top:3rem!important;padding-bottom:3rem!important}.pt-xxl-0{padding-top:0!important}.pt-xxl-1{padding-top:.25rem!important}.pt-xxl-2{padding-top:.5rem!important}.pt-xxl-3{padding-top:1rem!important}.pt-xxl-4{padding-top:1.5rem!important}.pt-xxl-5{padding-top:3rem!important}.pe-xxl-0{padding-right:0!important}.pe-xxl-1{padding-right:.25rem!important}.pe-xxl-2{padding-right:.5rem!important}.pe-xxl-3{padding-right:1rem!important}.pe-xxl-4{padding-right:1.5rem!important}.pe-xxl-5{padding-right:3rem!important}.pb-xxl-0{padding-bottom:0!important}.pb-xxl-1{padding-bottom:.25rem!important}.pb-xxl-2{padding-bottom:.5rem!important}.pb-xxl-3{padding-bottom:1rem!important}.pb-xxl-4{padding-bottom:1.5rem!important}.pb-xxl-5{padding-bottom:3rem!important}.ps-xxl-0{padding-left:0!important}.ps-xxl-1{padding-left:.25rem!important}.ps-xxl-2{padding-left:.5rem!important}.ps-xxl-3{padding-left:1rem!important}.ps-xxl-4{padding-left:1.5rem!important}.ps-xxl-5{padding-left:3rem!important}.text-xxl-start{text-align:left!important}.text-xxl-end{text-align:right!important}.text-xxl-center{text-align:center!important}}@media (min-width:1200px){.fs-1{font-size:2.5rem!important}.fs-2{font-size:2rem!important}.fs-3{font-size:1.75rem!important}.fs-4{font-size:1.5rem!important}}@media print{.d-print-inline{display:inline!important}.d-print-inline-block{display:inline-block!important}.d-print-block{display:block!important}.d-print-grid{display:grid!important}.d-print-table{display:table!important}.d-print-table-row{display:table-row!important}.d-print-table-cell{display:table-cell!important}.d-print-flex{display:flex!important}.d-print-inline-flex{display:inline-flex!important}.d-print-none{display:none!important}} +/*# sourceMappingURL=bootstrap.min.css.map */ \ No newline at end of file diff --git a/src/css/flatpickr.min.css b/src/css/flatpickr.min.css new file mode 100644 index 0000000..2b5da59 --- /dev/null +++ b/src/css/flatpickr.min.css @@ -0,0 +1,13 @@ +.flatpickr-calendar{background:transparent;opacity:0;display:none;text-align:center;visibility:hidden;padding:0;-webkit-animation:none;animation:none;direction:ltr;border:0;font-size:14px;line-height:24px;border-radius:5px;position:absolute;width:307.875px;-webkit-box-sizing:border-box;box-sizing:border-box;-ms-touch-action:manipulation;touch-action:manipulation;background:#fff;-webkit-box-shadow:1px 0 0 #e6e6e6,-1px 0 0 #e6e6e6,0 1px 0 #e6e6e6,0 -1px 0 #e6e6e6,0 3px 13px rgba(0,0,0,0.08);box-shadow:1px 0 0 #e6e6e6,-1px 0 0 #e6e6e6,0 1px 0 #e6e6e6,0 -1px 0 #e6e6e6,0 3px 13px rgba(0,0,0,0.08)}.flatpickr-calendar.open,.flatpickr-calendar.inline{opacity:1;max-height:640px;visibility:visible}.flatpickr-calendar.open{display:inline-block;z-index:99999}.flatpickr-calendar.animate.open{-webkit-animation:fpFadeInDown 300ms cubic-bezier(.23,1,.32,1);animation:fpFadeInDown 300ms cubic-bezier(.23,1,.32,1)}.flatpickr-calendar.inline{display:block;position:relative;top:2px}.flatpickr-calendar.static{position:absolute;top:calc(100% + 2px)}.flatpickr-calendar.static.open{z-index:999;display:block}.flatpickr-calendar.multiMonth .flatpickr-days .dayContainer:nth-child(n+1) .flatpickr-day.inRange:nth-child(7n+7){-webkit-box-shadow:none !important;box-shadow:none !important}.flatpickr-calendar.multiMonth .flatpickr-days .dayContainer:nth-child(n+2) .flatpickr-day.inRange:nth-child(7n+1){-webkit-box-shadow:-2px 0 0 #e6e6e6,5px 0 0 #e6e6e6;box-shadow:-2px 0 0 #e6e6e6,5px 0 0 #e6e6e6}.flatpickr-calendar .hasWeeks .dayContainer,.flatpickr-calendar .hasTime .dayContainer{border-bottom:0;border-bottom-right-radius:0;border-bottom-left-radius:0}.flatpickr-calendar .hasWeeks .dayContainer{border-left:0}.flatpickr-calendar.hasTime .flatpickr-time{height:40px;border-top:1px solid #e6e6e6}.flatpickr-calendar.noCalendar.hasTime .flatpickr-time{height:auto}.flatpickr-calendar:before,.flatpickr-calendar:after{position:absolute;display:block;pointer-events:none;border:solid transparent;content:'';height:0;width:0;left:22px}.flatpickr-calendar.rightMost:before,.flatpickr-calendar.arrowRight:before,.flatpickr-calendar.rightMost:after,.flatpickr-calendar.arrowRight:after{left:auto;right:22px}.flatpickr-calendar.arrowCenter:before,.flatpickr-calendar.arrowCenter:after{left:50%;right:50%}.flatpickr-calendar:before{border-width:5px;margin:0 -5px}.flatpickr-calendar:after{border-width:4px;margin:0 -4px}.flatpickr-calendar.arrowTop:before,.flatpickr-calendar.arrowTop:after{bottom:100%}.flatpickr-calendar.arrowTop:before{border-bottom-color:#e6e6e6}.flatpickr-calendar.arrowTop:after{border-bottom-color:#fff}.flatpickr-calendar.arrowBottom:before,.flatpickr-calendar.arrowBottom:after{top:100%}.flatpickr-calendar.arrowBottom:before{border-top-color:#e6e6e6}.flatpickr-calendar.arrowBottom:after{border-top-color:#fff}.flatpickr-calendar:focus{outline:0}.flatpickr-wrapper{position:relative;display:inline-block}.flatpickr-months{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex}.flatpickr-months .flatpickr-month{background:transparent;color:rgba(0,0,0,0.9);fill:rgba(0,0,0,0.9);height:34px;line-height:1;text-align:center;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;overflow:hidden;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1}.flatpickr-months .flatpickr-prev-month,.flatpickr-months .flatpickr-next-month{text-decoration:none;cursor:pointer;position:absolute;top:0;height:34px;padding:10px;z-index:3;color:rgba(0,0,0,0.9);fill:rgba(0,0,0,0.9)}.flatpickr-months .flatpickr-prev-month.flatpickr-disabled,.flatpickr-months .flatpickr-next-month.flatpickr-disabled{display:none}.flatpickr-months .flatpickr-prev-month i,.flatpickr-months .flatpickr-next-month i{position:relative}.flatpickr-months .flatpickr-prev-month.flatpickr-prev-month,.flatpickr-months .flatpickr-next-month.flatpickr-prev-month{/* + /*rtl:begin:ignore*/left:0/* + /*rtl:end:ignore*/}/* + /*rtl:begin:ignore*/ +/* + /*rtl:end:ignore*/ +.flatpickr-months .flatpickr-prev-month.flatpickr-next-month,.flatpickr-months .flatpickr-next-month.flatpickr-next-month{/* + /*rtl:begin:ignore*/right:0/* + /*rtl:end:ignore*/}/* + /*rtl:begin:ignore*/ +/* + /*rtl:end:ignore*/ +.flatpickr-months .flatpickr-prev-month:hover,.flatpickr-months .flatpickr-next-month:hover{color:#959ea9}.flatpickr-months .flatpickr-prev-month:hover svg,.flatpickr-months .flatpickr-next-month:hover svg{fill:#f64747}.flatpickr-months .flatpickr-prev-month svg,.flatpickr-months .flatpickr-next-month svg{width:14px;height:14px}.flatpickr-months .flatpickr-prev-month svg path,.flatpickr-months .flatpickr-next-month svg path{-webkit-transition:fill .1s;transition:fill .1s;fill:inherit}.numInputWrapper{position:relative;height:auto}.numInputWrapper input,.numInputWrapper span{display:inline-block}.numInputWrapper input{width:100%}.numInputWrapper input::-ms-clear{display:none}.numInputWrapper input::-webkit-outer-spin-button,.numInputWrapper input::-webkit-inner-spin-button{margin:0;-webkit-appearance:none}.numInputWrapper span{position:absolute;right:0;width:14px;padding:0 4px 0 2px;height:50%;line-height:50%;opacity:0;cursor:pointer;border:1px solid rgba(57,57,57,0.15);-webkit-box-sizing:border-box;box-sizing:border-box}.numInputWrapper span:hover{background:rgba(0,0,0,0.1)}.numInputWrapper span:active{background:rgba(0,0,0,0.2)}.numInputWrapper span:after{display:block;content:"";position:absolute}.numInputWrapper span.arrowUp{top:0;border-bottom:0}.numInputWrapper span.arrowUp:after{border-left:4px solid transparent;border-right:4px solid transparent;border-bottom:4px solid rgba(57,57,57,0.6);top:26%}.numInputWrapper span.arrowDown{top:50%}.numInputWrapper span.arrowDown:after{border-left:4px solid transparent;border-right:4px solid transparent;border-top:4px solid rgba(57,57,57,0.6);top:40%}.numInputWrapper span svg{width:inherit;height:auto}.numInputWrapper span svg path{fill:rgba(0,0,0,0.5)}.numInputWrapper:hover{background:rgba(0,0,0,0.05)}.numInputWrapper:hover span{opacity:1}.flatpickr-current-month{font-size:135%;line-height:inherit;font-weight:300;color:inherit;position:absolute;width:75%;left:12.5%;padding:7.48px 0 0 0;line-height:1;height:34px;display:inline-block;text-align:center;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}.flatpickr-current-month span.cur-month{font-family:inherit;font-weight:700;color:inherit;display:inline-block;margin-left:.5ch;padding:0}.flatpickr-current-month span.cur-month:hover{background:rgba(0,0,0,0.05)}.flatpickr-current-month .numInputWrapper{width:6ch;width:7ch\0;display:inline-block}.flatpickr-current-month .numInputWrapper span.arrowUp:after{border-bottom-color:rgba(0,0,0,0.9)}.flatpickr-current-month .numInputWrapper span.arrowDown:after{border-top-color:rgba(0,0,0,0.9)}.flatpickr-current-month input.cur-year{background:transparent;-webkit-box-sizing:border-box;box-sizing:border-box;color:inherit;cursor:text;padding:0 0 0 .5ch;margin:0;display:inline-block;font-size:inherit;font-family:inherit;font-weight:300;line-height:inherit;height:auto;border:0;border-radius:0;vertical-align:initial;-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield}.flatpickr-current-month input.cur-year:focus{outline:0}.flatpickr-current-month input.cur-year[disabled],.flatpickr-current-month input.cur-year[disabled]:hover{font-size:100%;color:rgba(0,0,0,0.5);background:transparent;pointer-events:none}.flatpickr-current-month .flatpickr-monthDropdown-months{appearance:menulist;background:transparent;border:none;border-radius:0;box-sizing:border-box;color:inherit;cursor:pointer;font-size:inherit;font-family:inherit;font-weight:300;height:auto;line-height:inherit;margin:-1px 0 0 0;outline:none;padding:0 0 0 .5ch;position:relative;vertical-align:initial;-webkit-box-sizing:border-box;-webkit-appearance:menulist;-moz-appearance:menulist;width:auto}.flatpickr-current-month .flatpickr-monthDropdown-months:focus,.flatpickr-current-month .flatpickr-monthDropdown-months:active{outline:none}.flatpickr-current-month .flatpickr-monthDropdown-months:hover{background:rgba(0,0,0,0.05)}.flatpickr-current-month .flatpickr-monthDropdown-months .flatpickr-monthDropdown-month{background-color:transparent;outline:none;padding:0}.flatpickr-weekdays{background:transparent;text-align:center;overflow:hidden;width:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;height:28px}.flatpickr-weekdays .flatpickr-weekdaycontainer{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1}span.flatpickr-weekday{cursor:default;font-size:90%;background:transparent;color:rgba(0,0,0,0.54);line-height:1;margin:0;text-align:center;display:block;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;font-weight:bolder}.dayContainer,.flatpickr-weeks{padding:1px 0 0 0}.flatpickr-days{position:relative;overflow:hidden;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start;width:307.875px}.flatpickr-days:focus{outline:0}.dayContainer{padding:0;outline:0;text-align:left;width:307.875px;min-width:307.875px;max-width:307.875px;-webkit-box-sizing:border-box;box-sizing:border-box;display:inline-block;display:-ms-flexbox;display:-webkit-box;display:-webkit-flex;display:flex;-webkit-flex-wrap:wrap;flex-wrap:wrap;-ms-flex-wrap:wrap;-ms-flex-pack:justify;-webkit-justify-content:space-around;justify-content:space-around;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0);opacity:1}.dayContainer + .dayContainer{-webkit-box-shadow:-1px 0 0 #e6e6e6;box-shadow:-1px 0 0 #e6e6e6}.flatpickr-day{background:none;border:1px solid transparent;border-radius:150px;-webkit-box-sizing:border-box;box-sizing:border-box;color:#393939;cursor:pointer;font-weight:400;width:14.2857143%;-webkit-flex-basis:14.2857143%;-ms-flex-preferred-size:14.2857143%;flex-basis:14.2857143%;max-width:39px;height:39px;line-height:39px;margin:0;display:inline-block;position:relative;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;text-align:center}.flatpickr-day.inRange,.flatpickr-day.prevMonthDay.inRange,.flatpickr-day.nextMonthDay.inRange,.flatpickr-day.today.inRange,.flatpickr-day.prevMonthDay.today.inRange,.flatpickr-day.nextMonthDay.today.inRange,.flatpickr-day:hover,.flatpickr-day.prevMonthDay:hover,.flatpickr-day.nextMonthDay:hover,.flatpickr-day:focus,.flatpickr-day.prevMonthDay:focus,.flatpickr-day.nextMonthDay:focus{cursor:pointer;outline:0;background:#e6e6e6;border-color:#e6e6e6}.flatpickr-day.today{border-color:#959ea9}.flatpickr-day.today:hover,.flatpickr-day.today:focus{border-color:#959ea9;background:#959ea9;color:#fff}.flatpickr-day.selected,.flatpickr-day.startRange,.flatpickr-day.endRange,.flatpickr-day.selected.inRange,.flatpickr-day.startRange.inRange,.flatpickr-day.endRange.inRange,.flatpickr-day.selected:focus,.flatpickr-day.startRange:focus,.flatpickr-day.endRange:focus,.flatpickr-day.selected:hover,.flatpickr-day.startRange:hover,.flatpickr-day.endRange:hover,.flatpickr-day.selected.prevMonthDay,.flatpickr-day.startRange.prevMonthDay,.flatpickr-day.endRange.prevMonthDay,.flatpickr-day.selected.nextMonthDay,.flatpickr-day.startRange.nextMonthDay,.flatpickr-day.endRange.nextMonthDay{background:#569ff7;-webkit-box-shadow:none;box-shadow:none;color:#fff;border-color:#569ff7}.flatpickr-day.selected.startRange,.flatpickr-day.startRange.startRange,.flatpickr-day.endRange.startRange{border-radius:50px 0 0 50px}.flatpickr-day.selected.endRange,.flatpickr-day.startRange.endRange,.flatpickr-day.endRange.endRange{border-radius:0 50px 50px 0}.flatpickr-day.selected.startRange + .endRange:not(:nth-child(7n+1)),.flatpickr-day.startRange.startRange + .endRange:not(:nth-child(7n+1)),.flatpickr-day.endRange.startRange + .endRange:not(:nth-child(7n+1)){-webkit-box-shadow:-10px 0 0 #569ff7;box-shadow:-10px 0 0 #569ff7}.flatpickr-day.selected.startRange.endRange,.flatpickr-day.startRange.startRange.endRange,.flatpickr-day.endRange.startRange.endRange{border-radius:50px}.flatpickr-day.inRange{border-radius:0;-webkit-box-shadow:-5px 0 0 #e6e6e6,5px 0 0 #e6e6e6;box-shadow:-5px 0 0 #e6e6e6,5px 0 0 #e6e6e6}.flatpickr-day.flatpickr-disabled,.flatpickr-day.flatpickr-disabled:hover,.flatpickr-day.prevMonthDay,.flatpickr-day.nextMonthDay,.flatpickr-day.notAllowed,.flatpickr-day.notAllowed.prevMonthDay,.flatpickr-day.notAllowed.nextMonthDay{color:rgba(57,57,57,0.3);background:transparent;border-color:transparent;cursor:default}.flatpickr-day.flatpickr-disabled,.flatpickr-day.flatpickr-disabled:hover{cursor:not-allowed;color:rgba(57,57,57,0.1)}.flatpickr-day.week.selected{border-radius:0;-webkit-box-shadow:-5px 0 0 #569ff7,5px 0 0 #569ff7;box-shadow:-5px 0 0 #569ff7,5px 0 0 #569ff7}.flatpickr-day.hidden{visibility:hidden}.rangeMode .flatpickr-day{margin-top:1px}.flatpickr-weekwrapper{float:left}.flatpickr-weekwrapper .flatpickr-weeks{padding:0 12px;-webkit-box-shadow:1px 0 0 #e6e6e6;box-shadow:1px 0 0 #e6e6e6}.flatpickr-weekwrapper .flatpickr-weekday{float:none;width:100%;line-height:28px}.flatpickr-weekwrapper span.flatpickr-day,.flatpickr-weekwrapper span.flatpickr-day:hover{display:block;width:100%;max-width:none;color:rgba(57,57,57,0.3);background:transparent;cursor:default;border:none}.flatpickr-innerContainer{display:block;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden}.flatpickr-rContainer{display:inline-block;padding:0;-webkit-box-sizing:border-box;box-sizing:border-box}.flatpickr-time{text-align:center;outline:0;display:block;height:0;line-height:40px;max-height:40px;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex}.flatpickr-time:after{content:"";display:table;clear:both}.flatpickr-time .numInputWrapper{-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;width:40%;height:40px;float:left}.flatpickr-time .numInputWrapper span.arrowUp:after{border-bottom-color:#393939}.flatpickr-time .numInputWrapper span.arrowDown:after{border-top-color:#393939}.flatpickr-time.hasSeconds .numInputWrapper{width:26%}.flatpickr-time.time24hr .numInputWrapper{width:49%}.flatpickr-time input{background:transparent;-webkit-box-shadow:none;box-shadow:none;border:0;border-radius:0;text-align:center;margin:0;padding:0;height:inherit;line-height:inherit;color:#393939;font-size:14px;position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield}.flatpickr-time input.flatpickr-hour{font-weight:bold}.flatpickr-time input.flatpickr-minute,.flatpickr-time input.flatpickr-second{font-weight:400}.flatpickr-time input:focus{outline:0;border:0}.flatpickr-time .flatpickr-time-separator,.flatpickr-time .flatpickr-am-pm{height:inherit;float:left;line-height:inherit;color:#393939;font-weight:bold;width:2%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-align-self:center;-ms-flex-item-align:center;align-self:center}.flatpickr-time .flatpickr-am-pm{outline:0;width:18%;cursor:pointer;text-align:center;font-weight:400}.flatpickr-time input:hover,.flatpickr-time .flatpickr-am-pm:hover,.flatpickr-time input:focus,.flatpickr-time .flatpickr-am-pm:focus{background:#eee}.flatpickr-input[readonly]{cursor:pointer}@-webkit-keyframes fpFadeInDown{from{opacity:0;-webkit-transform:translate3d(0,-20px,0);transform:translate3d(0,-20px,0)}to{opacity:1;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}}@keyframes fpFadeInDown{from{opacity:0;-webkit-transform:translate3d(0,-20px,0);transform:translate3d(0,-20px,0)}to{opacity:1;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}} \ No newline at end of file diff --git a/css/jquery.growl.css b/src/css/jquery.growl.css similarity index 100% rename from css/jquery.growl.css rename to src/css/jquery.growl.css diff --git a/src/css/main.css b/src/css/main.css new file mode 100644 index 0000000..24c77b6 --- /dev/null +++ b/src/css/main.css @@ -0,0 +1 @@ +@import"https://fonts.googleapis.com/css?family=Open+Sans:400&subset=cyrillic,cyrillic-ext,greek,greek-ext,latin-ext,vietnamese";@import"https://fonts.googleapis.com/css?family=Fira+Sans:400,700&subset=cyrillic,cyrillic-ext,greek,greek-ext,latin-ext,vietnamese";body{background:#fff;margin:0;min-height:100vh;line-height:24px;font-family:"Open Sans",sans-serif;display:flex;flex-direction:column}body .h1,body .h2,body .h3,body h1,body h2,body h3{margin-top:18px}img{height:auto;max-width:100%}a{padding:0;margin:0;text-decoration:none}a:hover,a:focus{text-decoration:none;color:#f5f4f4}.centered{text-align:center}#switch{height:auto;line-height:34px;font-size:25px;margin-bottom:5px}#switch .switch{position:relative;display:inline-block;width:60px;height:34px}#switch .switch input{opacity:0;width:0;height:0}#switch .switch .slider{position:absolute;cursor:pointer;top:0;left:0;right:0;bottom:0;background-color:#ccc;-webkit-transition:.4s;transition:.4s}#switch .switch .slider:before{position:absolute;content:"";height:26px;width:26px;left:4px;bottom:4px;background-color:#fff;-webkit-transition:.4s;transition:.4s}#switch .switch .slider.round{border-radius:34px}#switch .switch .slider.round:before{border-radius:50%}#switch input:checked+.slider{background-color:#2196f3}#switch input:focus+.slider{box-shadow:0 0 1px #2196f3}#switch input:checked+.slider:before{transform:translateX(26px)}header{background-color:#2f60a3}main.container{max-width:1024px;min-height:calc(100vh - 157px);padding-right:15px;padding-left:15px;margin-left:auto;margin-right:auto}main.container#install .settings{padding-bottom:25px}main.container#install .settings,main.container#install form .card:not(:first-child){margin-top:30px}main.container#status #status-big,main.container#dashboard #status-big{margin-bottom:20px;padding:15px;border-radius:5px;font-size:1.3em}main.container#status #timeline,main.container#dashboard #timeline{margin-top:50px}main.container#status #timeline h3,main.container#dashboard #timeline h3{margin-top:24px;padding-left:70px;margin-bottom:15px}main.container#status .timeline,main.container#dashboard .timeline{position:relative;padding:0 0px 10px;margin-top:4px}main.container#status .timeline .line,main.container#dashboard .timeline .line{position:absolute;width:2px;display:block;background:#c2c2c2;top:0px;bottom:0px;margin-left:31px}main.container#status .timeline .line::before,main.container#dashboard .timeline .line::before{top:0;left:-4px;content:"";position:absolute;width:10px;height:10px;border-radius:50%;background:#c2c2c2}main.container#status .timeline .servicelist,main.container#dashboard .timeline .servicelist{position:relative;margin:10px 0px 21px 70px;clear:both}main.container#status .timeline .card,main.container#dashboard .timeline .card{margin:10px 0px 21px 70px}main.container#status .timeline .card::before,main.container#dashboard .timeline .card::before{position:absolute;top:8px;left:-24px;content:"";border:inherit;border-width:12px;border-top-color:transparent;border-bottom-color:transparent;border-left-color:transparent}main.container#status .timeline .card .card-colore.icon,main.container#dashboard .timeline .card .card-colore.icon{position:absolute;left:-59px;width:40px;height:40px;border-radius:50%;text-align:center}main.container#status .timeline .card .card-colore.icon i,main.container#dashboard .timeline .card .card-colore.icon i{font-size:20px;line-height:40px}main.container#status .timeline .card .card-footer p,main.container#dashboard .timeline .card .card-footer p{margin:0}main.container#status .timeline .card .card-footer .card-title,main.container#dashboard .timeline .card .card-footer .card-title{font-size:.9em}main.container#status .timeline .card .card-footer .card-badge,main.container#dashboard .timeline .card .card-footer .card-badge{font-size:.75em}main.container#status{font-size:1.05em}main.container#dashboard #status{width:230px;display:block;text-align:right}main.container#dashboard .card-header.bg-primary input#title{width:70%}main.container#dashboard .card-header:not(.border-primary) input#title{width:100%}main.container#dashboard .card-header:not(.border-primary) #time,main.container#dashboard .card-header:not(.border-primary) #end_time_wrapper{display:none}main.container#dashboard article.card input{background:transparent;border:none;border-bottom:1px #fff outset}main.container#dashboard article.card textarea{width:100%;background:transparent;border:none;resize:vertical;min-height:100px}main.container#dashboard article.card .delete{margin-left:5px;font-size:1.2em;color:#fff;line-height:25px}main.container#dashboard article.card .delete:hover,main.container#dashboard article.card .delete:focus{color:#eee}main.container#dashboard #status-container.error input{box-shadow:0px 0 2px 1px red}main.container#login .wrapper{padding-top:20px}main.container#settings .input-group-text{width:230px}main.container .status.success{color:#30aa5b}main.container .status.warning{color:#edaa16}main.container .status.danger{color:#e74c3c}main.container .status.primary{color:#3a72bd}main.container .card-success{border-color:#30aa5b}main.container .card-warning{border-color:#edaa16}main.container .card-danger{border-color:#e74c3c}main.container .card-success .card-header,main.container #status-big.success{background:#30aa5b;border-color:rgba(0,0,0,.1)}main.container .card-warning .card-header,main.container #status-big.warning{background:#edaa16;border-color:rgba(0,0,0,.1)}main.container .card-danger .card-header,main.container #status-big.danger{background:#e74c3c;border-color:rgba(0,0,0,.1)}main.container .card-primary{border-color:#337ab7}main.container .card-primary .card-header,main.container #status-big.primary{background:#337ab7;border-color:rgba(0,0,0,.1)}main.container #status-big.primary{background:#3a72bd}footer#footerwrap{min-height:60px;padding-top:15px;padding-bottom:10px;background-color:#2f60a3}footer#footerwrap .dropdown-menu{background-color:#3a72bd}footer#footerwrap .dropdown-menu a{color:#fff;width:100%;padding:2px 5px;display:block;background-color:#3a72bd}footer#footerwrap .dropdown-menu a:hover{background-color:#2f60a3}footer#footerwrap .btn-group img{max-height:20px;max-width:25px;margin-right:5px;vertical-align:middle}body[data-theme=dark]{background-color:#333}body[data-theme=dark] header,body[data-theme=dark] .navbar-default{background:#202225}body[data-theme=dark] footer#footerwrap{background:#202225}body[data-theme=dark] main{color:#fff}body[data-theme=dark] .fa-moon::before{content:""}body[data-theme=dark] .list-group-item{border-color:rgba(255,255,255,.125)}body[data-theme=dark] .list-group-item.sub-component{background-color:#333;color:#fff}body[data-theme=dark] .card{background-color:#333;color:#fff}body[data-theme=dark] .card .card-footer{border-color:rgba(255,255,255,.125)}body[data-theme=dark] .table{color:#fff}.navbar-default .navbar-nav>li>a{color:#f5f4f4;font-size:1rem}.navbar-default h1{color:#f5f4f4;font-size:1.15rem;display:inline-block}.navbar-brand{line-height:50px}.navbar-brand img{display:inline-block}.navbar-default .navbar-nav>li>a:hover{color:#a7a7a7}.navbar-default .navbar-nav>.active>a,.navbar-default .navbar-nav>.active>a:hover,.navbar-default .navbar-nav>.active>a:focus{color:#f5f4f4;background-color:transparent}.navbar-default{z-index:200;background-color:#2f60a3;border-color:transparent;height:77px;position:relative;top:0;width:100%}.navbar-right{margin-top:15px}.navbar-left{margin-top:8px}div.center{margin-left:auto;margin-right:auto}.wrapper{max-width:1024px;width:100%;padding-right:15px;padding-left:15px;flex-grow:1;padding-bottom:32px;display:flex;flex-direction:column}.list-group-item strong{font-family:"Fira Sans",sans-serif}.group-name{font-weight:600}.group-parent{position:relative;padding-left:2.25rem !important}.group-parent{position:relative;padding-left:2.25rem !important}.group-parent.collapsed::after{content:"+"}.group-parent::after{font-weight:700;width:1rem;left:1rem;display:block;text-align:center;position:absolute;content:"-";top:50%;transform:translateY(-50%)}.list-group-item.collapsed~.sub-component{display:none}.list-group-item.collapsed{border-bottom-right-radius:inherit;border-bottom-left-radius:inherit}.service{float:left;box-sizing:border-box;padding:15px 35px;font-weight:bold;font-size:1.1em;font-family:"Fira Sans",sans-serif}body a h1{font-size:1.3em;margin:0;line-height:1.3em}.status{box-sizing:border-box;text-align:right;font-size:.95rem;font-family:"Fira Sans",sans-serif}.list-group-item .status{margin-left:1rem}.navbar-header .btn{margin-top:15px;margin-right:10px}.wrapper .card-header{color:#fff}#status-big{width:100%;margin-bottom:15px;float:none;color:#fff;text-align:left;padding:15px;border-radius:5px;font-size:1.3em;font-family:"Fira Sans",sans-serif}.timeline .card .card-header.icon *{font-size:20px;vertical-align:middle;line-height:40px}.timeline .card .card-header.icon{position:absolute;left:-59px;display:block;width:40px;height:40px;padding:0px;border-radius:50%;text-align:center;float:left}#login-form{max-width:500px;padding-top:20px;width:100%}.navbar-right.navbar-admin{margin-top:10px}.card-footer input,.card-header input{background:transparent;border:none;border-bottom:1px solid #777}input.error{border-bottom:1px solid red;color:red}input,textarea{outline:none}body .card-header input{color:#fff}.card.card-primary input#title{width:50%}#time input{max-width:100%}.card.card-primary #time{display:inline-block;float:right;width:40%;max-width:40%}.card.card-primary input#title{width:50%;max-width:50%}.card:not(.card-primary) input#title{width:100%}.card:not(.card-primary) #time,.card:not(.card-primary) #end_time_wrapper{display:none}.card-body textarea{width:100%;background:transparent;border:none;resize:vertical;min-height:100px}#type{width:auto}.wrapper.admin #timeline{padding-top:0}.wrapper.admin #timeline .service{padding-left:15px}.wrapper.admin #timeline .service input[type=checkbox]{margin-right:4px;margin-top:0;vertical-align:middle}body.admin table td{word-break:break-all}section{padding-top:20px}section h3{margin:0;margin-bottom:20px;line-height:34px}i.success{color:#30aa5b}i.danger{color:#e74c3c}.col-md-2 strong{line-height:34px}.table-responsive{width:100%}.col-md-6{line-height:34px}.margin-top{margin-top:10px}#status-container.error input{box-shadow:0px 0 2px 1px red}.delete{margin-left:5px;font-size:1.2em;color:#fff;line-height:25px}.delete:hover,.delete:focus{color:#eee}.new-service{width:40%;min-width:250px}.delete-service{color:red;font-size:1em}.service label{margin-bottom:0}.install{padding-bottom:25px}.install .btn{margin-top:30px}.col-md-4.text-left,.col-md-4.text-right{line-height:2.5}.dropup hr.divider{margin:2px;border:1px}.row.user .input-group{width:100%;margin-bottom:5px}.row.user .form-name{width:50%;float:left}#new-incident{margin:10px 0px 21px 70px}#new-incident .card.new{margin:0 !important;margin-top:24px !important;margin-bottom:24px !important}label.form-name{line-height:20px}.card .card-footer .label{display:inline-block}.navbar-brand h1{display:inline-block}.list-group-item{padding:1rem 1.8rem}.switch{position:relative;display:inline-block;width:60px;height:34px}.switch input{opacity:0;width:0;height:0}.slider{position:absolute;cursor:pointer;top:0;left:0;right:0;bottom:0;background-color:#ccc;-webkit-transition:.4s;transition:.4s}.slider:before{position:absolute;content:"";height:26px;width:26px;left:4px;bottom:4px;background-color:#fff;-webkit-transition:.4s;transition:.4s}input:checked+.slider{background-color:#2196f3}input:focus+.slider{box-shadow:0 0 1px #2196f3}input:checked+.slider:before{-webkit-transform:translateX(26px);-ms-transform:translateX(26px);transform:translateX(26px)}.slider.round{border-radius:34px}.slider.round:before{border-radius:50%} diff --git a/src/css/main.scss b/src/css/main.scss new file mode 100644 index 0000000..65d9b5b --- /dev/null +++ b/src/css/main.scss @@ -0,0 +1,883 @@ +@import url('https://fonts.googleapis.com/css?family=Open+Sans:400&subset=cyrillic,cyrillic-ext,greek,greek-ext,latin-ext,vietnamese'); +@import url('https://fonts.googleapis.com/css?family=Fira+Sans:400,700&subset=cyrillic,cyrillic-ext,greek,greek-ext,latin-ext,vietnamese'); + +$bg_light: #fff; +$text_light: #111; +$bg_dark: #333; +$text_dark: #fff; +$border_dark: rgba(255, 255, 255, 0.125); +$main_dark: #202225; +$main_light: #2f60a3; + +body { + background: #ffffff; + margin: 0; + min-height: 100vh; + line-height: 24px; + font-family: 'Open Sans', sans-serif; + display: flex; + flex-direction: column; + + .h1, + .h2, + .h3, + h1, + h2, + h3 { + margin-top: 18px; + } +} + +img { + height: auto; + max-width: 100%; +} + +a { + padding: 0; + margin: 0; + text-decoration: none; + + &:hover, + &:focus { + text-decoration: none; + color: #f5f4f4; + } +} + +.centered { + text-align: center; +} + +#switch { + height: auto; + line-height: 34px; + font-size: 25px; + margin-bottom: 5px; + + .switch { + position: relative; + display: inline-block; + width: 60px; + height: 34px; + + input { + opacity: 0; + width: 0; + height: 0; + } + + .slider { + position: absolute; + cursor: pointer; + top: 0; + left: 0; + right: 0; + bottom: 0; + background-color: #ccc; + -webkit-transition: 0.4s; + transition: 0.4s; + + &:before { + position: absolute; + content: ''; + height: 26px; + width: 26px; + left: 4px; + bottom: 4px; + background-color: white; + -webkit-transition: 0.4s; + transition: 0.4s; + } + + &.round { + border-radius: 34px; + + &:before { + border-radius: 50%; + } + } + } + } + + input { + &:checked + .slider { + background-color: #2196f3; + } + + &:focus + .slider { + box-shadow: 0 0 1px #2196f3; + } + + &:checked + .slider:before { + transform: translateX(26px); + } + } +} + +header { + background-color: $main_light; +} + +main.container { + max-width: 1024px; + min-height: calc(100vh - 157px); + padding-right: 15px; + padding-left: 15px; + margin-left: auto; + margin-right: auto; + + &#install { + .settings { + padding-bottom: 25px; + } + + .settings, + form .card:not(:first-child) { + margin-top: 30px; + } + } + + &#status, + &#dashboard { + #status-big { + margin-bottom: 20px; + padding: 15px; + border-radius: 5px; + font-size: 1.3em; + } + + #timeline { + margin-top: 50px; + + h3 { + margin-top: 24px; + padding-left: 70px; + margin-bottom: 15px; + } + } + + .timeline { + position: relative; + padding: 0 0px 10px; + margin-top: 4px; + + .line { + position: absolute; + width: 2px; + display: block; + background: #c2c2c2; + top: 0px; + bottom: 0px; + margin-left: 31px; + + &::before { + top: 0; + left: -4px; + content: ''; + position: absolute; + width: 10px; + height: 10px; + border-radius: 50%; + background: #c2c2c2; + } + } + + .servicelist { + position: relative; + margin: 10px 0px 21px 70px; + clear: both; + } + + .card { + margin: 10px 0px 21px 70px; + + &::before { + position: absolute; + top: 8px; + left: -24px; + content: ''; + border: inherit; + border-width: 12px; + border-top-color: transparent; + border-bottom-color: transparent; + border-left-color: transparent; + } + + .card-colore.icon { + position: absolute; + left: -59px; + width: 40px; + height: 40px; + border-radius: 50%; + text-align: center; + + i { + font-size: 20px; + line-height: 40px; + } + } + + .card-footer { + p { + margin: 0; + } + + .card-title { + font-size: 0.9em; + } + + .card-badge { + font-size: 0.75em; + } + } + } + } + } + + &#status { + font-size: 1.05em; + } + + &#dashboard { + #status { + width: 230px; + display: block; + text-align: right; + } + + .card-header.bg-primary input#title { + width: 70%; + } + + .card-header:not(.border-primary) { + input#title { + width: 100%; + } + + #time, + #end_time_wrapper { + display: none; + } + } + + article.card { + input { + background: transparent; + border: none; + border-bottom: 1px white outset; + } + + textarea { + width: 100%; + background: transparent; + border: none; + resize: vertical; + min-height: 100px; + } + + .delete { + margin-left: 5px; + font-size: 1.2em; + color: white; + line-height: 25px; + + &:hover, + &:focus { + color: #eee; + } + } + } + + #status-container.error input { + box-shadow: 0px 0 2px 1px rgba(255, 0, 0, 1); + } + } + + &#login { + .wrapper { + padding-top: 20px; + } + } + + &#settings { + .input-group-text { + width: 230px; + } + } + + .status.success { + color: #30aa5b; + } + + .status.warning { + color: #edaa16; + } + + .status.danger { + color: #e74c3c; + } + + .status.primary { + color: #3a72bd; + } + + .card-success { + border-color: #30aa5b; + } + + .card-warning { + border-color: #edaa16; + } + + .card-danger { + border-color: #e74c3c; + } + + .card-success .card-header, + #status-big.success { + background: #30aa5b; + border-color: rgba(0, 0, 0, 0.1); + } + .card-warning .card-header, + #status-big.warning { + background: #edaa16; + border-color: rgba(0, 0, 0, 0.1); + } + + .card-danger .card-header, + #status-big.danger { + background: #e74c3c; + border-color: rgba(0, 0, 0, 0.1); + } + + .card-primary { + border-color: #337ab7; + } + .card-primary .card-header, + #status-big.primary { + background: #337ab7; + border-color: rgba(0, 0, 0, 0.1); + } + + #status-big.primary { + background: #3a72bd; + } +} + +footer#footerwrap { + min-height: 60px; + padding-top: 15px; + padding-bottom: 10px; + background-color: $main_light; + + .dropdown-menu { + background-color: #3a72bd; + + a { + color: white; + width: 100%; + padding: 2px 5px; + display: block; + background-color: #3a72bd; + + &:hover { + background-color: #2f60a3; + } + } + } + + .btn-group img { + max-height: 20px; + max-width: 25px; + margin-right: 5px; + vertical-align: middle; + } +} + +// Dark theme +body[data-theme='dark'] { + background-color: $bg_dark; + + header, + .navbar-default { + background: $main_dark; + } + + footer#footerwrap { + background: $main_dark; + } + + main { + color: $text_dark; + } + + .fa-moon::before { + content: ''; + } + + .list-group-item { + border-color: $border_dark; + + &.sub-component { + background-color: $bg_dark; + color: $text_dark; + } + } + + .card { + background-color: $bg_dark; + color: $text_dark; + + .card-footer { + border-color: $border_dark; + } + } + + .table { + color: $text_dark; + } +} + +// OLD +.navbar-default .navbar-nav > li > a { + color: #f5f4f4; + font-size: 1rem; +} + +.navbar-default h1 { + color: #f5f4f4; + font-size: 1.15rem; + display: inline-block; +} + +.navbar-brand { + line-height: 50px; +} + +.navbar-brand img { + display: inline-block; +} + +.navbar-default .navbar-nav > li > a:hover { + color: #a7a7a7; +} + +.navbar-default .navbar-nav > .active > a, +.navbar-default .navbar-nav > .active > a:hover, +.navbar-default .navbar-nav > .active > a:focus { + color: #f5f4f4; + background-color: transparent; +} + +.navbar-default { + z-index: 200; + background-color: $main_light; + border-color: transparent; + height: 77px; + position: relative; + top: 0; + width: 100%; +} + +.navbar-right { + margin-top: 15px; +} + +.navbar-left { + margin-top: 8px; +} + +div.center { + margin-left: auto; + margin-right: auto; +} + +.wrapper { + max-width: 1024px; + width: 100%; + padding-right: 15px; + padding-left: 15px; + flex-grow: 1; + padding-bottom: 32px; + display: flex; + flex-direction: column; +} + +.list-group-item strong { + font-family: 'Fira Sans', sans-serif; +} + +.group-name { + font-weight: 600; +} + +.group-parent { + position: relative; + padding-left: 2.25rem !important; +} + +.group-parent { + position: relative; + padding-left: 2.25rem !important; +} +.group-parent.collapsed::after { + content: '+'; +} + +.group-parent::after { + font-weight: 700; + width: 1rem; + left: 1rem; + display: block; + text-align: center; + position: absolute; + content: '-'; + top: 50%; + transform: translateY(-50%); +} + +.list-group-item.collapsed ~ .sub-component { + display: none; +} + +.list-group-item.collapsed { + border-bottom-right-radius: inherit; + border-bottom-left-radius: inherit; +} + +.service { + float: left; + box-sizing: border-box; + padding: 15px 35px; + font-weight: bold; + font-size: 1.1em; + font-family: 'Fira Sans', sans-serif; +} + +body a h1 { + font-size: 1.3em; + margin: 0; + line-height: 1.3em; +} + +.status { + box-sizing: border-box; + text-align: right; + font-size: 0.95rem; + font-family: 'Fira Sans', sans-serif; +} + +.list-group-item .status { + margin-left: 1rem; +} + +.navbar-header .btn { + margin-top: 15px; + margin-right: 10px; +} + +.wrapper .card-header { + color: white; +} + +#status-big { + width: 100%; + margin-bottom: 15px; + float: none; + color: white; + text-align: left; + padding: 15px; + border-radius: 5px; + font-size: 1.3em; + font-family: 'Fira Sans', sans-serif; +} + +.timeline .card .card-header.icon * { + /*This shouldn't be relative in size...*/ + font-size: 20px; + vertical-align: middle; + line-height: 40px; +} + +.timeline .card .card-header.icon { + position: absolute; + left: -59px; + display: block; + width: 40px; + height: 40px; + padding: 0px; + border-radius: 50%; + text-align: center; + float: left; +} + +#login-form { + max-width: 500px; + padding-top: 20px; + width: 100%; +} + +.navbar-right.navbar-admin { + margin-top: 10px; +} + +.card-footer input, +.card-header input { + background: transparent; + border: none; + border-bottom: 1px solid #777; +} + +input.error { + border-bottom: 1px solid red; + color: red; +} + +input, +textarea { + outline: none; +} + +body .card-header input { + color: white; +} + +.card.card-primary input#title { + width: 50%; +} + +#time input { + max-width: 100%; +} + +.card.card-primary #time { + display: inline-block; + float: right; + width: 40%; + max-width: 40%; +} + +.card.card-primary input#title { + width: 50%; + max-width: 50%; +} + +.card:not(.card-primary) input#title { + width: 100%; +} + +.card:not(.card-primary) #time, +.card:not(.card-primary) #end_time_wrapper { + display: none; +} + +.card-body textarea { + width: 100%; + background: transparent; + border: none; + resize: vertical; + min-height: 100px; +} + +#type { + width: auto; +} + +.wrapper.admin #timeline { + padding-top: 0; +} + +.wrapper.admin #timeline .service { + padding-left: 15px; +} + +.wrapper.admin #timeline .service input[type='checkbox'] { + margin-right: 4px; + margin-top: 0; + vertical-align: middle; +} + +body.admin table td { + word-break: break-all; +} + +section { + padding-top: 20px; +} + +section h3 { + margin: 0; + margin-bottom: 20px; + line-height: 34px; +} + +i.success { + color: #30aa5b; +} + +i.danger { + color: #e74c3c; +} + +.col-md-2 strong { + line-height: 34px; +} + +.table-responsive { + width: 100%; +} + +.col-md-6 { + line-height: 34px; +} + +.margin-top { + margin-top: 10px; +} + +#status-container.error input { + box-shadow: 0px 0 2px 1px rgba(255, 0, 0, 1); +} + +.delete { + margin-left: 5px; + font-size: 1.2em; + color: white; + line-height: 25px; +} + +.delete:hover, +.delete:focus { + color: #eee; +} + +.new-service { + width: 40%; + min-width: 250px; +} + +.delete-service { + color: red; + font-size: 1em; +} + +.service label { + margin-bottom: 0; +} + +.install { + padding-bottom: 25px; +} + +.install .btn { + margin-top: 30px; +} + +.col-md-4.text-left, +.col-md-4.text-right { + line-height: 2.5; +} + +.dropup hr.divider { + margin: 2px; + border: 1px; +} + +.row.user .input-group { + width: 100%; + margin-bottom: 5px; +} + +.row.user .form-name { + width: 50%; + float: left; +} + +#new-incident { + margin: 10px 0px 21px 70px; + + .card.new { + margin: 0 !important; + margin-top: 24px !important; + margin-bottom: 24px !important; + } +} + +label.form-name { + line-height: 20px; +} +.card .card-footer .label { + display: inline-block; +} + +.navbar-brand h1 { + display: inline-block; +} + +.list-group-item { + padding: 1rem 1.8rem; +} + +/* The switch - the box around the slider */ +.switch { + position: relative; + display: inline-block; + width: 60px; + height: 34px; +} + +/* Hide default HTML checkbox */ +.switch input { + opacity: 0; + width: 0; + height: 0; +} + +/* The slider */ +.slider { + position: absolute; + cursor: pointer; + top: 0; + left: 0; + right: 0; + bottom: 0; + background-color: #ccc; + -webkit-transition: 0.4s; + transition: 0.4s; +} + +.slider:before { + position: absolute; + content: ''; + height: 26px; + width: 26px; + left: 4px; + bottom: 4px; + background-color: white; + -webkit-transition: 0.4s; + transition: 0.4s; +} + +input:checked + .slider { + background-color: #2196f3; +} + +input:focus + .slider { + box-shadow: 0 0 1px #2196f3; +} + +input:checked + .slider:before { + -webkit-transform: translateX(26px); + -ms-transform: translateX(26px); + transform: translateX(26px); +} + +/* Rounded sliders */ +.slider.round { + border-radius: 34px; +} + +.slider.round:before { + border-radius: 50%; +} diff --git a/src/css/print.css b/src/css/print.css new file mode 100644 index 0000000..dc6c917 --- /dev/null +++ b/src/css/print.css @@ -0,0 +1,140 @@ +@import url(https://fonts.googleapis.com/css?family=Open+Sans:400); +@import url(https://fonts.googleapis.com/css?family=Fira+Sans:400,700); + +body { + background: #ffffff; + margin: 0; + height: 100%; + line-height: 24px; + font-family: 'Open Sans', sans-serif; +} + +#status-container +{ + border-radius: 0; + border-top: 1px solid #e0e0e0; + border-bottom: 1px solid #e0e0e0; +} + +#status-container .item:last-child +{ + border: none; +} + +#status-container .item{ + border-bottom: 1px solid #e0e0e0; +} + +#status-big +{ + float: none; + width: 100%; + text-align: center; + font-family: 'Fira Sans', sans-serif; + font-size: 1.5em +} + +.wrapper{ + padding-left: 20%; + padding-right: 20%; +} + +.service{ + float: left; + box-sizing: border-box; + width:60%; + min-width: 200px; + padding: 15px 35px; + font-weight: bold; + font-size: 1em; + font-family: 'Fira Sans', sans-serif; +} + +.status{ + float: left; + box-sizing: border-box; + width:40%; + min-width: 150px; + padding: 15px 35px; + text-align: right; + font-size: 0.8em; + font-family: 'Fira Sans', sans-serif; +} + + +#status-container .status.success{ + color:#2fcc66!important; + font-weight: bolder; +} + +#status-container .status.warning{ + color:#edaa16!important; + font-weight: bolder; +} + +#status-container .status.danger{ + color:#e74c3c!important; + font-weight: bolder; +} + +#status-container .status.primary{ + color:#3A72BD!important; + font-weight: bolder; +} + +.panel-success{ + border-color:#2fcc66; +} +#footerwrap{ + display: none +} +.btn +{ + display: none +} + +h3{ + text-align: center; +} + +.panel-heading.icon{ + width: 50px; + float: left; + border: none; +} + +h2.panel-title{ + float: left; +} + +.panel,.panel-heading,.panel-footer{ + border-width: 3px +} + +body .panel-danger, +.panel-danger > .panel-body, +.panel-danger > .panel-heading, +.panel-danger > .panel-footer{ + border-color: #a94442 +} + +body .panel-success, +.panel-success > .panel-body, +.panel-success > .panel-heading, +.panel-success > .panel-footer{ + border-color: #2fcc66 +} + +body .panel-warning, +.panel-warning > .panel-body, +.panel-warning > .panel-heading, +.panel-warning > .panel-footer{ + border-color: #edaa16 +} + +body .panel-primary, +.panel-primary > .panel-body, +.panel-primary > .panel-heading, +.panel-primary > .panel-footer{ + border-color: #337ab7 +} \ No newline at end of file diff --git a/src/email_subscriptions.php b/src/email_subscriptions.php new file mode 100644 index 0000000..702308d --- /dev/null +++ b/src/email_subscriptions.php @@ -0,0 +1,206 @@ +getSetting($mysqli, "name")); +define("TITLE", $db->getSetting($mysqli, "title")); +define("WEB_URL", $db->getSetting($mysqli, "url")); +define("MAILER_NAME", $db->getSetting($mysqli, "mailer")); +define("MAILER_ADDRESS", $db->getSetting($mysqli, "mailer_email")); +define("GOOGLE_RECAPTCHA", $db->getBooleanSetting($mysqli, "google_recaptcha")); +//define("", $db->getSettings($mysqli, "")); +define("GOOGLE_RECAPTCHA_SECRET", $db->getSetting($mysqli, "google_recaptcha_secret")); +define("GOOGLE_RECAPTCHA_SITEKEY", $db->getSetting($mysqli, "google_recaptcha_sitekey")); +define("SUBSCRIBE_EMAIL", $db->getBooleanSetting($mysqli, "subscribe_email")); +define("SUBSCRIBE_TELEGRAM", $db->getBooleanSetting($mysqli, "subscribe_telegram")); +define("TG_BOT_USERNAME", $db->getSetting($mysqli, "tg_bot_username")); +define("TG_BOT_API_TOKEN", $db->getSetting($mysqli, "tg_bot_api_token")); +define("PHP_MAILER", $db->getBooleanSetting($mysqli, "php_mailer")); +define("PHP_MAILER_SMTP", $db->getBooleanSetting($mysqli, "php_mailer_smtp")); +define("PHP_MAILER_PATH", $db->getSetting($mysqli, "php_mailer_path")); +define("PHP_MAILER_HOST", $db->getSetting($mysqli, "php_mailer_host")); +define("PHP_MAILER_PORT", $db->getSetting($mysqli, "php_mailer_port")); +define("PHP_MAILER_SECURE", $db->getBooleanSetting($mysqli, "php_mailer_secure")); +define("PHP_MAILER_USER", $db->getSetting($mysqli, "php_mailer_user")); +define("PHP_MAILER_PASS", $db->getSetting($mysqli, "php_mailer_pass")); + +$mailer = new Mailer(); +$subscriber = new Subscriber(); +$subscription = new Subscriptions(); + + +$boolRegistered = false; + +if (isset($_GET['new'])) { + // Form validation for subscribers signing up + $message = ""; + Template::render_header(_("Email Subscription"), "subsmail"); + + if (isset($_POST['emailaddress'])) { + if (0 == strlen(trim($_POST['emailaddress']))) { + $messages[] = _("Email address"); + } + + // Perform DNS domain validation on + if (!$mailer->verify_domain($_POST['emailaddress'])) { + $messages[] = _("Domain does not apper to be a valid email domain. (Check MX record)"); + } + + if (GOOGLE_RECAPTCHA) { + // Validate recaptcha + $response = $_POST["g-recaptcha-response"]; + $url = 'https://www.google.com/recaptcha/api/siteverify'; + $data = array( + 'secret' => GOOGLE_RECAPTCHA_SECRET, + 'response' => $_POST["g-recaptcha-response"] + ); + $options = array( + 'http' => array( + 'header' => 'Content-Type: application/x-www-form-urlencoded\r\n', + 'method' => 'POST', + 'content' => http_build_query($data) + ) + ); + $context = stream_context_create($options); + $verify = file_get_contents($url, false, $context); + $captcha_success = json_decode($verify); + + if ($captcha_success->success == false) { + $messages[] = _("reChaptcha validation failed"); + } + } + if (isset($messages)) { + $message = _("Please check
            "); + $message .= implode("
            ", $messages); + } + } + + if (isset($_POST['emailaddress']) && empty($message)) { + // Check if email is already registered + $boolUserExist = false; + $subscriber->userID = $_POST['emailaddress']; + $subscriber->typeID = 2; // Email + $boolUserExist = $subscriber->check_userid_exist(); + + $url = WEB_URL . "/index.php?do=manage&token=" . $subscriber->token; + + if (!$boolUserExist) { + // Create a new subscriber as it does not exist + $subscriber->add($subscriber->typeID, $_POST['emailaddress']); + $url = WEB_URL . "/index.php?do=manage&token=" . $subscriber->token; // Needed again after adding subscriber since token did not exist before add + $msg = sprintf(_("Thank you for registering to receive status updates via email.

            Click on the following link to confirm and manage your subcription: %s. New subscriptions must be confirmed within 2 hours"), $url, NAME . ' - ' . _("Validate subscription")); + } else { + if (!$subscriber->active) { + // Subscriber is registered, but has not been activated yet... + $msg = sprintf(_("Thank you for registering to receive status updates via email.

            Click on the following link to confirm and manage your subcription: %s. New subscriptions must be confirmed within 2 hours"), $url, NAME . ' - ' . _("Validate subscription")); + $subscriber->activate($subscriber->id); + } else { + // subscriber is registered and active + $msg = sprintf(_("Click on the following link to update your existing subscription: %s"), $url, NAME . ' - ' . _("Manage subscription")); + $subscriber->update($subscriber->id); + } + } + // Show success message + $header = _("Thank you for subscribing"); + $message = _("You will receive an email shortly with an activation link. Please click on the link to activate and/or manage your subscription."); + $constellation->render_success($header, $message, true, WEB_URL, _('Go back')); + + // Send email about new registration + $subject = _('Email subscription registered') . ' - ' . NAME; + $mailer->send_mail($_POST['emailaddress'], $subject, $msg); + + $boolRegistered = true; + } + + // Add a new email subscriber - display form + if (isset($_GET['new']) && (!$boolRegistered)) { + if (!empty($message)) { + echo '

            ' . $message . '

            '; + } + $strPostedEmail = (isset($_POST['emailaddress'])) ? $_POST['emailaddress'] : ""; + ?> + + +
            +

            +
            + + +
            + +
            +
            +
            +
            +
            +
            +
            + + + Privacy Policy'), POLICY_URL); + echo $msg; + ?> + +
            +
            + + +
            + typeID = 2; //EMAIL + if ($subscriber->is_active_subscriber($_GET['token'])) { + // forward user to subscriber list.... + $subscriber->set_logged_in(); + header('Location: subscriptions.php'); + exit; + } else { + Template::render_header(_("Email Subscription"), "subsmail"); + + $header = _("We cannot find a valid subscriber account matching those details"); + $message = _("If you have recently subscribed, please make sure you activate the account within two hours of doing so. You are welcome to try and re-subscribe."); + $constellation->render_warning($header, $message, true, WEB_URL, _('Go back')); + } +} elseif (isset($_GET['do']) && $_GET['do'] == 'unsubscribe') { + // Handle unsubscriptions + // TODO This function is universal and should probably live elsewhere?? + if (isset($_GET['token'])) { + $subscriber->typeID = (int) $_GET['type']; + + if ($subscriber->get_subscriber_by_token($_GET['token'])) { + $subscriber->delete($subscriber->id); + $subscriber->set_logged_off(); + Template::render_header(_("Email Subscription"), "subsmail"); + + $header = _("You have been unsubscribed from our system"); + $message = _("We are sorry to see you go. If you want to subscribe again at a later date please feel free to re-subscribe."); + $constellation->render_success($header, $message, true, WEB_URL, _('Go back')); + } else { + // TODO Log token for troubleshooting ? + // Cannot find subscriber - show alert + Template::render_header(_("Email Subscription"), "subsmail"); + $header = _("We are unable to find any valid subscriber detail matching your submitted data!"); + $message = _("If you believe this to be an error, please contact the system admininistrator."); + $constellation->render_warning($header, $message, true, WEB_URL, _('Go back')); + + // + } + } else { + // TODO Log $_GET[] for troubleshooting ? + $header = _("We are unable to find any valid subscriber detail matching your submitted data!"); + $message = _("If you believe this to be an error, please contact the system admininistrator."); + $constellation->render_warning($header, $message, true, WEB_URL, _('Go back')); + } +} +Template::render_footer(); diff --git a/favicon/android-icon-144x144.png b/src/favicon/android-icon-144x144.png similarity index 100% rename from favicon/android-icon-144x144.png rename to src/favicon/android-icon-144x144.png diff --git a/favicon/android-icon-192x192.png b/src/favicon/android-icon-192x192.png similarity index 100% rename from favicon/android-icon-192x192.png rename to src/favicon/android-icon-192x192.png diff --git a/favicon/android-icon-36x36.png b/src/favicon/android-icon-36x36.png similarity index 100% rename from favicon/android-icon-36x36.png rename to src/favicon/android-icon-36x36.png diff --git a/favicon/android-icon-48x48.png b/src/favicon/android-icon-48x48.png similarity index 100% rename from favicon/android-icon-48x48.png rename to src/favicon/android-icon-48x48.png diff --git a/favicon/android-icon-72x72.png b/src/favicon/android-icon-72x72.png similarity index 100% rename from favicon/android-icon-72x72.png rename to src/favicon/android-icon-72x72.png diff --git a/favicon/android-icon-96x96.png b/src/favicon/android-icon-96x96.png similarity index 100% rename from favicon/android-icon-96x96.png rename to src/favicon/android-icon-96x96.png diff --git a/favicon/apple-icon-114x114.png b/src/favicon/apple-icon-114x114.png similarity index 100% rename from favicon/apple-icon-114x114.png rename to src/favicon/apple-icon-114x114.png diff --git a/favicon/apple-icon-120x120.png b/src/favicon/apple-icon-120x120.png similarity index 100% rename from favicon/apple-icon-120x120.png rename to src/favicon/apple-icon-120x120.png diff --git a/favicon/apple-icon-144x144.png b/src/favicon/apple-icon-144x144.png similarity index 100% rename from favicon/apple-icon-144x144.png rename to src/favicon/apple-icon-144x144.png diff --git a/favicon/apple-icon-152x152.png b/src/favicon/apple-icon-152x152.png similarity index 100% rename from favicon/apple-icon-152x152.png rename to src/favicon/apple-icon-152x152.png diff --git a/favicon/apple-icon-180x180.png b/src/favicon/apple-icon-180x180.png similarity index 100% rename from favicon/apple-icon-180x180.png rename to src/favicon/apple-icon-180x180.png diff --git a/favicon/apple-icon-57x57.png b/src/favicon/apple-icon-57x57.png similarity index 100% rename from favicon/apple-icon-57x57.png rename to src/favicon/apple-icon-57x57.png diff --git a/favicon/apple-icon-60x60.png b/src/favicon/apple-icon-60x60.png similarity index 100% rename from favicon/apple-icon-60x60.png rename to src/favicon/apple-icon-60x60.png diff --git a/favicon/apple-icon-72x72.png b/src/favicon/apple-icon-72x72.png similarity index 100% rename from favicon/apple-icon-72x72.png rename to src/favicon/apple-icon-72x72.png diff --git a/favicon/apple-icon-76x76.png b/src/favicon/apple-icon-76x76.png similarity index 100% rename from favicon/apple-icon-76x76.png rename to src/favicon/apple-icon-76x76.png diff --git a/favicon/apple-icon-precomposed.png b/src/favicon/apple-icon-precomposed.png similarity index 100% rename from favicon/apple-icon-precomposed.png rename to src/favicon/apple-icon-precomposed.png diff --git a/favicon/apple-icon.png b/src/favicon/apple-icon.png similarity index 100% rename from favicon/apple-icon.png rename to src/favicon/apple-icon.png diff --git a/favicon/browserconfig.xml b/src/favicon/browserconfig.xml similarity index 100% rename from favicon/browserconfig.xml rename to src/favicon/browserconfig.xml diff --git a/favicon/favicon-16x16.png b/src/favicon/favicon-16x16.png similarity index 100% rename from favicon/favicon-16x16.png rename to src/favicon/favicon-16x16.png diff --git a/favicon/favicon-32x32.png b/src/favicon/favicon-32x32.png similarity index 100% rename from favicon/favicon-32x32.png rename to src/favicon/favicon-32x32.png diff --git a/favicon/favicon-96x96.png b/src/favicon/favicon-96x96.png similarity index 100% rename from favicon/favicon-96x96.png rename to src/favicon/favicon-96x96.png diff --git a/favicon/favicon.ico b/src/favicon/favicon.ico similarity index 100% rename from favicon/favicon.ico rename to src/favicon/favicon.ico diff --git a/favicon/manifest.json b/src/favicon/manifest.json similarity index 100% rename from favicon/manifest.json rename to src/favicon/manifest.json diff --git a/favicon/ms-icon-144x144.png b/src/favicon/ms-icon-144x144.png similarity index 100% rename from favicon/ms-icon-144x144.png rename to src/favicon/ms-icon-144x144.png diff --git a/favicon/ms-icon-150x150.png b/src/favicon/ms-icon-150x150.png similarity index 100% rename from favicon/ms-icon-150x150.png rename to src/favicon/ms-icon-150x150.png diff --git a/favicon/ms-icon-310x310.png b/src/favicon/ms-icon-310x310.png similarity index 100% rename from favicon/ms-icon-310x310.png rename to src/favicon/ms-icon-310x310.png diff --git a/favicon/ms-icon-70x70.png b/src/favicon/ms-icon-70x70.png similarity index 100% rename from favicon/ms-icon-70x70.png rename to src/favicon/ms-icon-70x70.png diff --git a/src/fonts/bootstrap-icons.woff b/src/fonts/bootstrap-icons.woff new file mode 100644 index 0000000..8cd8946 Binary files /dev/null and b/src/fonts/bootstrap-icons.woff differ diff --git a/src/fonts/bootstrap-icons.woff2 b/src/fonts/bootstrap-icons.woff2 new file mode 100644 index 0000000..3e587fd Binary files /dev/null and b/src/fonts/bootstrap-icons.woff2 differ diff --git a/head.txt b/src/head.txt similarity index 100% rename from head.txt rename to src/head.txt diff --git a/img/logo_white.png b/src/img/logo_white.png similarity index 100% rename from img/logo_white.png rename to src/img/logo_white.png diff --git a/src/index.php b/src/index.php new file mode 100644 index 0000000..a32eeab --- /dev/null +++ b/src/index.php @@ -0,0 +1,89 @@ +getSetting($mysqli, "name")); + define("TITLE", $db->getSetting($mysqli, "title")); + define("WEB_URL", $db->getSetting($mysqli, "url")); + define("MAILER_NAME", $db->getSetting($mysqli, "mailer")); + define("MAILER_ADDRESS", $db->getSetting($mysqli, "mailer_email")); + + define("SUBSCRIBE_EMAIL", $db->getBooleanSetting($mysqli, "subscribe_email")); + define("SUBSCRIBE_TELEGRAM", $db->getBooleanSetting($mysqli, "subscribe_telegram")); + define("TG_BOT_USERNAME", $db->getSetting($mysqli, "tg_bot_username")); + define("TG_BOT_API_TOKEN", $db->getSetting($mysqli, "tg_bot_api_token")); + define("GOOGLE_RECAPTCHA", $db->getBooleanSetting($mysqli, "google_recaptcha")); + define("GOOGLE_RECAPTCHA_SITEKEY", $db->getSetting($mysqli, "google_recaptcha_sitekey")); + define("GOOGLE_RECAPTCHA_SECRET", $db->getSetting($mysqli, "google_recaptcha_secret")); + $offset = 0; + + if (isset($_GET['ajax'])) { + $constellation->render_incidents(false, $_GET['offset'], 5); + exit(); + } elseif (isset($_GET['offset'])) { + $offset = $_GET['offset']; + } + + if (isset($_GET['subscriber_logout'])) { + setcookie('tg_user', ''); + setcookie('referer', '', time() - 3600); + $_SESSION['subscriber_valid'] = false; + unset($_SESSION['subscriber_userid']); + unset($_SESSION['subscriber_typeid']); + unset($_SESSION['subscriber_id']); + header('Location: index.php'); + } + + Template::render_header("Status", "status"); + ?> +
            +

            +
            +
            + render_status(); ?> +
            + + query('SELECT count(*) FROM status')->num_rows) { + ?> +
            +
            + render_incidents(true, $offset); + $constellation->render_incidents(false, $offset); + ?> +
            + negotiate($override); + $_SESSION['locale'] = $best_match; + setlocale(LC_ALL, $_SESSION['locale'] . ".UTF-8"); + + bindtextdomain("server-status", __DIR__ . "/locale/"); + bind_textdomain_codeset($_SESSION['locale'], "utf-8"); + textdomain("server-status"); +} + +if (isset($_POST['server'])) { + $mysqli = new mysqli($_POST['server'], $_POST['dbuser'], $_POST['dbpassword'], $_POST['database']); + + if ($mysqli->connect_errno) { + $message .= sprintf(_("Connection failed: %s\n"), $mysqli->connect_error); + } + + if (isset($_POST['url']) && filter_var($_POST['url'], FILTER_VALIDATE_URL) === false) { + $message .= _("Please set valid url!"); + } + + //Ostatní má checky existence ve funkci pro pridani + if (0 == strlen(trim($_POST['servername']))) { + $messages[] = _("Server name"); + } + + if (0 == strlen(trim($_POST['url']))) { + $messages[] = _("Url"); + } + + if (0 == strlen(trim($_POST['mailer']))) { + $messages[] = _("Mailer name"); + } + + if (0 == strlen(trim($_POST['title']))) { + $messages[] = _("Title"); + } + + if (0 == strlen(trim($_POST['mailer_email']))) { + $messages[] = _("Mailer email"); + } + + if (0 == strlen(trim($_POST['server']))) { + $messages[] = _("Database server"); + } + + if (0 == strlen(trim($_POST['database']))) { + $messages[] = _("Database name"); + } + + if (0 == strlen(trim($_POST['dbuser']))) { + $messages[] = _("Database user"); + } + + if (0 == strlen(trim($_POST['dbpassword']))) { + $messages[] = _("Database password"); + } + if (isset($messages)) { + $message .= _("Please enter"); + $message .= implode(", ", $messages); + } +} + +if (isset($_POST['server']) && empty($message)) { + define("MAILER_NAME", $_POST['mailer']); + define("MAILER_ADDRESS", $_POST['mailer_email']); + define("INSTALL_OVERRIDE", true); + + //No need to include config, as we have connection from testing it... :) + //There may be better way to do this... + $sql = file_get_contents("install.sql"); + $array = explode(";", $sql); + + foreach ($array as $value) { + $val = trim($value); + if (empty($val)) { + continue; + } + $q_res = $mysqli->query($value); + if ($q_res === false) { + $message = sprintf(_("Error while creating database. Please check permission for your account or MYSQL version.
            Error: %s"), $mysqli->error); + break; + } + } + + if (empty($message)) { + require_once("classes/constellation.php"); + + User::add(); + } + + if (empty($message)) { + //Create config + $config = file_get_contents("config.php.template"); + //$config = str_replace("##name##", htmlspecialchars($_POST['servername'], ENT_QUOTES), $config); + $db->setSetting($mysqli, "name", htmlspecialchars($_POST['servername'], ENT_QUOTES)); + //$config = str_replace("##title##", htmlspecialchars($_POST['title'], ENT_QUOTES), $config); + $db->setSetting($mysqli, "title", htmlspecialchars($_POST['title'], ENT_QUOTES)); + //$config = str_replace("##url##", $_POST['url'], $config); + $db->setSetting($mysqli, "url", $_POST['url']); + //$config = str_replace("##mailer##", htmlspecialchars($_POST['mailer'], ENT_QUOTES), $config); + $db->setSetting($mysqli, "mailer", htmlspecialchars($_POST['mailer'], ENT_QUOTES)); + //$config = str_replace("##mailer_email##", htmlspecialchars($_POST['mailer_email'], ENT_QUOTES), $config); + $db->setSetting($mysqli, "mailer_email", htmlspecialchars($_POST['mailer_email'], ENT_QUOTES)); + $config = str_replace("##server##", htmlspecialchars($_POST['server'], ENT_QUOTES), $config); + $config = str_replace("##database##", htmlspecialchars($_POST['database'], ENT_QUOTES), $config); + $config = str_replace("##user##", htmlspecialchars($_POST['dbuser'], ENT_QUOTES), $config); + $config = str_replace("##password##", htmlspecialchars($_POST['dbpassword'], ENT_QUOTES), $config); + // Duplicate of lines 122-123 //$config = str_replace("##name##", htmlspecialchars($_POST['servername'], ENT_QUOTES), $config); + $config = str_replace("##policy_name##", htmlspecialchars($_POST['policy_name'], ENT_QUOTES), $config); + $config = str_replace("##address##", htmlspecialchars($_POST['address'], ENT_QUOTES), $config); + $config = str_replace("##policy_mail##", htmlspecialchars($_POST['policy_mail'], ENT_QUOTES), $config); + $config = str_replace("##policy_phone##", htmlspecialchars($_POST['policy_phone'], ENT_QUOTES), $config); + $config = str_replace("##who_we_are##", htmlspecialchars($_POST['who_we_are'], ENT_QUOTES), $config); + $policy_url_conf = (!empty($_POST['policy_url'])) ? htmlspecialchars($_POST['policy_url'], ENT_QUOTES) : $_POST['url'] . "/policy.php"; + $config = str_replace("##policy_url##", $policy_url_conf, $config); + + file_put_contents("config.php", $config); + + include_once "create-server-config.php"; + $db->setSetting($mysqli, "dbConfigVersion", "Version2Beta7"); + $db->setSetting($mysqli, "notifyUpdates", "yes"); + $db->setSetting($mysqli, "subscribe_email", "no"); + $db->setSetting($mysqli, "subscribe_telegram", "no"); + $db->setSetting($mysqli, "tg_bot_api_token", ""); + $db->setSetting($mysqli, "tg_bot_username", ""); + $db->setSetting($mysqli, "php_mailer", "no"); + $db->setSetting($mysqli, "php_mailer_host", ""); + $db->setSetting($mysqli, "php_mailer_smtp", "no"); + $db->setSetting($mysqli, "php_mailer_path", ""); + $db->setSetting($mysqli, "php_mailer_port", ""); + $db->setSetting($mysqli, "php_mailer_secure", "no"); + $db->setSetting($mysqli, "php_mailer_user", ""); + $db->setSetting($mysqli, "php_mailer_pass", ""); + $db->setSetting($mysqli, "google_recaptcha", "no"); + $db->setSetting($mysqli, "google_recaptcha_secret", ""); + $db->setSetting($mysqli, "google_recaptcha_sitekey", ""); + $db->setSetting($mysqli, "cron_server_ip", ""); + if (!$isDeveleoperEnvironement) { + unlink("create-server-config.php"); + unlink("config.php.template"); + unlink("install.sql"); + unlink(__FILE__); + } + header("Location: " . WEB_URL); + } +} +Template::render_header(_("Install"), "install"); + +$php_version_req = sprintf(_("Minimum PHP version %s"), MINIMUM_PHP_VERSION); +$preq_fail = array("times", "danger"); +$preq_ok = array("check", "success"); + +$preq_phpver = $preq_fail; +$preq_mysqlnd = $preq_fail; +$preq_writedir = $preq_fail; + +// Check if PHP version if > MINIMUM_PHP_VERSION +if (strnatcmp(phpversion(), MINIMUM_PHP_VERSION) >= 0) { + $preq_phpver = $preq_ok; +} + +// Test for mysqlnd precense. The mysqlnd driver provides some extra functions that is not available +// if the plain mysql package is installed, and mysqli_get_client_stats is one of them. This is documented +// on the PHP site at http://www.php.net/manual/en/mysqlnd.stats.php +// This test is also discussed at https://stackoverflow.com/questions/1475701/how-to-know-if-mysqlnd-is-the-active-driver +if (function_exists('mysqli_get_client_stats')) { + $preq_mysqlnd = $preq_ok; +} + +// Check if we have access to write to location +if (is_writable(__DIR__)) { + $preq_writedir = $preq_ok; +} + +?> +
            +
            +
            + +
            +
            + +

            +

            +
            +
            +
            +
            +
            +
            +
            +
            +
            +
            +
            +
            +
            +

            +
            +
            + +
            +

            + +

            + + + +
            +
            +
            + +
            +
            + https://example.com/status - without the trailing slash), so we can mail users link for forgotten password etc..."); ?> +

            +

            +
            + " class="form-control" required> + +
            +
            + " class="form-control" required> + +
            +
            +
            +
            + " class="form-control" required> + +
            +
            + " class="form-control" required> + +
            +
            +

            +
            +
            + +
            +
            + +
            +
            + +

            +

            +
            + " class="form-control" required> + +
            +
            + " class="form-control" required> + +
            +
            +
            +
            + " class="form-control" required> + +
            +
            + " class="form-control" required> + +
            +
            +

            +
            +
            + +
            +
            + +
            +
            + +

            +

            +
            + " class="form-control" required> + +
            +
            + " class="form-control" required> + +
            +
            +
            +
            + " class="form-control" required> + +
            +
            + " class="form-control"> + +
            +
            +
            +
            + + +
            +
            +
            + +
            + " class="form-control"> + +
            +
            +

            +
            +
            + +
            +
            + +
            +
            + +

            +

            +
            + " class="form-control" required> + +
            +
            + " class="form-control" required> + +
            +
            +
            +
            + " class="form-control" required> + +
            +
            + " class="form-control" required> + +
            +
            +
            +
            + " class="form-control" required> + +
            +
            +

            +
            +
            + +
            + + +
            +
            +
            +
            += end_time) { + $.growl.error({ message: "End time is either the same or earlier than start time!" }); + $("#time").addClass("error"); + $("#end_time").addClass("error"); + return false; + } + + if ($(".list-group.components :checkbox:checked").length === 0) { + $.growl.error({ message: "Please check at least one service!" }); + $(".list-group.components").addClass("error"); + return false; + } + } + ); +})(); + diff --git a/src/js/main.js b/src/js/main.js new file mode 100644 index 0000000..78b5395 --- /dev/null +++ b/src/js/main.js @@ -0,0 +1,80 @@ +function timeago() +{ + $("time.timeago").timeago(); + $("time.timeago").each( + function () { + var date = new Date($(this).attr("datetime")); + $(this).attr("title",date.toLocaleString()); + } + ); +} + +function initTheme() { + var darkThemeSelected = localStorage.getItem("darkSwitch") !== null && localStorage.getItem("darkSwitch") === "dark"; + darkSwitch.checked = darkThemeSelected; + darkThemeSelected ? document.body.setAttribute("data-theme", "dark") : document.body.removeAttribute("data-theme"); +} + +function resetTheme() { + if (darkSwitch.checked) { + document.body.setAttribute("data-theme", "dark"); + localStorage.setItem("darkSwitch", "dark"); + } else { + document.body.removeAttribute("data-theme"); + localStorage.removeItem("darkSwitch"); + } +} + +if (window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches) { + document.body.setAttribute("data-theme", "dark"); +} +window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change", (e) => { + const newColorScheme = e.matches ? document.body.setAttribute("data-theme", "dark") : document.body.removeAttribute("data-theme"); +}); + +(function () { + jQuery.timeago.settings.allowFuture = true; + + timeago(); + + $("body").on( + "click", ".navbar-toggle", function () { + $($(this).data("target")).toggleClass("collapse"); + } + ); + + var incidents = $('.timeline'); + $("body").on( + "click", "#loadmore", function (e) { + e.preventDefault(); + var url = $("#loadmore").attr("href") + "&ajax=true"; + $("#loadmore").remove(); + + $.get( + url, + function (data) { + incidents.append(data); + timeago(); + } + ); + } + ); + + $(document).ready(function(){ + $('[data-toggle="tooltip"]').tooltip(); + }); + + $('body').on('click', '.group-parent', function(e) { + e.preventDefault(); + $(e.target).closest('.group-parent').toggleClass('collapsed'); + }) + + var darkSwitch = document.getElementById("darkSwitch"); + + if (darkSwitch) { + initTheme(); + darkSwitch.addEventListener("change", function () { + resetTheme(); + }); + } +})(); \ No newline at end of file diff --git a/src/js/vendor/bootstrap.min.js b/src/js/vendor/bootstrap.min.js new file mode 100644 index 0000000..6f76e3b --- /dev/null +++ b/src/js/vendor/bootstrap.min.js @@ -0,0 +1,7 @@ +/*! + * Bootstrap v5.1.1 (https://getbootstrap.com/) + * Copyright 2011-2021 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) + * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) + */ +!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).bootstrap=e()}(this,(function(){"use strict";const t=t=>{let e=t.getAttribute("data-bs-target");if(!e||"#"===e){let i=t.getAttribute("href");if(!i||!i.includes("#")&&!i.startsWith("."))return null;i.includes("#")&&!i.startsWith("#")&&(i="#"+i.split("#")[1]),e=i&&"#"!==i?i.trim():null}return e},e=e=>{const i=t(e);return i&&document.querySelector(i)?i:null},i=e=>{const i=t(e);return i?document.querySelector(i):null},n=t=>{t.dispatchEvent(new Event("transitionend"))},s=t=>!(!t||"object"!=typeof t)&&(void 0!==t.jquery&&(t=t[0]),void 0!==t.nodeType),o=t=>s(t)?t.jquery?t[0]:t:"string"==typeof t&&t.length>0?document.querySelector(t):null,r=(t,e,i)=>{Object.keys(i).forEach(n=>{const o=i[n],r=e[n],a=r&&s(r)?"element":null==(l=r)?""+l:{}.toString.call(l).match(/\s([a-z]+)/i)[1].toLowerCase();var l;if(!new RegExp(o).test(a))throw new TypeError(`${t.toUpperCase()}: Option "${n}" provided type "${a}" but expected type "${o}".`)})},a=t=>!(!s(t)||0===t.getClientRects().length)&&"visible"===getComputedStyle(t).getPropertyValue("visibility"),l=t=>!t||t.nodeType!==Node.ELEMENT_NODE||!!t.classList.contains("disabled")||(void 0!==t.disabled?t.disabled:t.hasAttribute("disabled")&&"false"!==t.getAttribute("disabled")),c=t=>{if(!document.documentElement.attachShadow)return null;if("function"==typeof t.getRootNode){const e=t.getRootNode();return e instanceof ShadowRoot?e:null}return t instanceof ShadowRoot?t:t.parentNode?c(t.parentNode):null},h=()=>{},d=t=>{t.offsetHeight},u=()=>{const{jQuery:t}=window;return t&&!document.body.hasAttribute("data-bs-no-jquery")?t:null},f=[],p=()=>"rtl"===document.documentElement.dir,m=t=>{var e;e=()=>{const e=u();if(e){const i=t.NAME,n=e.fn[i];e.fn[i]=t.jQueryInterface,e.fn[i].Constructor=t,e.fn[i].noConflict=()=>(e.fn[i]=n,t.jQueryInterface)}},"loading"===document.readyState?(f.length||document.addEventListener("DOMContentLoaded",()=>{f.forEach(t=>t())}),f.push(e)):e()},g=t=>{"function"==typeof t&&t()},_=(t,e,i=!0)=>{if(!i)return void g(t);const s=(t=>{if(!t)return 0;let{transitionDuration:e,transitionDelay:i}=window.getComputedStyle(t);const n=Number.parseFloat(e),s=Number.parseFloat(i);return n||s?(e=e.split(",")[0],i=i.split(",")[0],1e3*(Number.parseFloat(e)+Number.parseFloat(i))):0})(e)+5;let o=!1;const r=({target:i})=>{i===e&&(o=!0,e.removeEventListener("transitionend",r),g(t))};e.addEventListener("transitionend",r),setTimeout(()=>{o||n(e)},s)},b=(t,e,i,n)=>{let s=t.indexOf(e);if(-1===s)return t[!i&&n?t.length-1:0];const o=t.length;return s+=i?1:-1,n&&(s=(s+o)%o),t[Math.max(0,Math.min(s,o-1))]},v=/[^.]*(?=\..*)\.|.*/,y=/\..*/,w=/::\d+$/,E={};let A=1;const T={mouseenter:"mouseover",mouseleave:"mouseout"},O=/^(mouseenter|mouseleave)/i,C=new Set(["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"]);function k(t,e){return e&&`${e}::${A++}`||t.uidEvent||A++}function L(t){const e=k(t);return t.uidEvent=e,E[e]=E[e]||{},E[e]}function x(t,e,i=null){const n=Object.keys(t);for(let s=0,o=n.length;sfunction(e){if(!e.relatedTarget||e.relatedTarget!==e.delegateTarget&&!e.delegateTarget.contains(e.relatedTarget))return t.call(this,e)};n?n=t(n):i=t(i)}const[o,r,a]=D(e,i,n),l=L(t),c=l[a]||(l[a]={}),h=x(c,r,o?i:null);if(h)return void(h.oneOff=h.oneOff&&s);const d=k(r,e.replace(v,"")),u=o?function(t,e,i){return function n(s){const o=t.querySelectorAll(e);for(let{target:r}=s;r&&r!==this;r=r.parentNode)for(let a=o.length;a--;)if(o[a]===r)return s.delegateTarget=r,n.oneOff&&P.off(t,s.type,e,i),i.apply(r,[s]);return null}}(t,i,n):function(t,e){return function i(n){return n.delegateTarget=t,i.oneOff&&P.off(t,n.type,e),e.apply(t,[n])}}(t,i);u.delegationSelector=o?i:null,u.originalHandler=r,u.oneOff=s,u.uidEvent=d,c[d]=u,t.addEventListener(a,u,o)}function N(t,e,i,n,s){const o=x(e[i],n,s);o&&(t.removeEventListener(i,o,Boolean(s)),delete e[i][o.uidEvent])}function I(t){return t=t.replace(y,""),T[t]||t}const P={on(t,e,i,n){S(t,e,i,n,!1)},one(t,e,i,n){S(t,e,i,n,!0)},off(t,e,i,n){if("string"!=typeof e||!t)return;const[s,o,r]=D(e,i,n),a=r!==e,l=L(t),c=e.startsWith(".");if(void 0!==o){if(!l||!l[r])return;return void N(t,l,r,o,s?i:null)}c&&Object.keys(l).forEach(i=>{!function(t,e,i,n){const s=e[i]||{};Object.keys(s).forEach(o=>{if(o.includes(n)){const n=s[o];N(t,e,i,n.originalHandler,n.delegationSelector)}})}(t,l,i,e.slice(1))});const h=l[r]||{};Object.keys(h).forEach(i=>{const n=i.replace(w,"");if(!a||e.includes(n)){const e=h[i];N(t,l,r,e.originalHandler,e.delegationSelector)}})},trigger(t,e,i){if("string"!=typeof e||!t)return null;const n=u(),s=I(e),o=e!==s,r=C.has(s);let a,l=!0,c=!0,h=!1,d=null;return o&&n&&(a=n.Event(e,i),n(t).trigger(a),l=!a.isPropagationStopped(),c=!a.isImmediatePropagationStopped(),h=a.isDefaultPrevented()),r?(d=document.createEvent("HTMLEvents"),d.initEvent(s,l,!0)):d=new CustomEvent(e,{bubbles:l,cancelable:!0}),void 0!==i&&Object.keys(i).forEach(t=>{Object.defineProperty(d,t,{get:()=>i[t]})}),h&&d.preventDefault(),c&&t.dispatchEvent(d),d.defaultPrevented&&void 0!==a&&a.preventDefault(),d}},j=new Map;var M={set(t,e,i){j.has(t)||j.set(t,new Map);const n=j.get(t);n.has(e)||0===n.size?n.set(e,i):console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(n.keys())[0]}.`)},get:(t,e)=>j.has(t)&&j.get(t).get(e)||null,remove(t,e){if(!j.has(t))return;const i=j.get(t);i.delete(e),0===i.size&&j.delete(t)}};class H{constructor(t){(t=o(t))&&(this._element=t,M.set(this._element,this.constructor.DATA_KEY,this))}dispose(){M.remove(this._element,this.constructor.DATA_KEY),P.off(this._element,this.constructor.EVENT_KEY),Object.getOwnPropertyNames(this).forEach(t=>{this[t]=null})}_queueCallback(t,e,i=!0){_(t,e,i)}static getInstance(t){return M.get(o(t),this.DATA_KEY)}static getOrCreateInstance(t,e={}){return this.getInstance(t)||new this(t,"object"==typeof e?e:null)}static get VERSION(){return"5.1.1"}static get NAME(){throw new Error('You have to implement the static method "NAME", for each component!')}static get DATA_KEY(){return"bs."+this.NAME}static get EVENT_KEY(){return"."+this.DATA_KEY}}const B=(t,e="hide")=>{const n="click.dismiss"+t.EVENT_KEY,s=t.NAME;P.on(document,n,`[data-bs-dismiss="${s}"]`,(function(n){if(["A","AREA"].includes(this.tagName)&&n.preventDefault(),l(this))return;const o=i(this)||this.closest("."+s);t.getOrCreateInstance(o)[e]()}))};class R extends H{static get NAME(){return"alert"}close(){if(P.trigger(this._element,"close.bs.alert").defaultPrevented)return;this._element.classList.remove("show");const t=this._element.classList.contains("fade");this._queueCallback(()=>this._destroyElement(),this._element,t)}_destroyElement(){this._element.remove(),P.trigger(this._element,"closed.bs.alert"),this.dispose()}static jQueryInterface(t){return this.each((function(){const e=R.getOrCreateInstance(this);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}B(R,"close"),m(R);class W extends H{static get NAME(){return"button"}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle("active"))}static jQueryInterface(t){return this.each((function(){const e=W.getOrCreateInstance(this);"toggle"===t&&e[t]()}))}}function z(t){return"true"===t||"false"!==t&&(t===Number(t).toString()?Number(t):""===t||"null"===t?null:t)}function q(t){return t.replace(/[A-Z]/g,t=>"-"+t.toLowerCase())}P.on(document,"click.bs.button.data-api",'[data-bs-toggle="button"]',t=>{t.preventDefault();const e=t.target.closest('[data-bs-toggle="button"]');W.getOrCreateInstance(e).toggle()}),m(W);const F={setDataAttribute(t,e,i){t.setAttribute("data-bs-"+q(e),i)},removeDataAttribute(t,e){t.removeAttribute("data-bs-"+q(e))},getDataAttributes(t){if(!t)return{};const e={};return Object.keys(t.dataset).filter(t=>t.startsWith("bs")).forEach(i=>{let n=i.replace(/^bs/,"");n=n.charAt(0).toLowerCase()+n.slice(1,n.length),e[n]=z(t.dataset[i])}),e},getDataAttribute:(t,e)=>z(t.getAttribute("data-bs-"+q(e))),offset(t){const e=t.getBoundingClientRect();return{top:e.top+window.pageYOffset,left:e.left+window.pageXOffset}},position:t=>({top:t.offsetTop,left:t.offsetLeft})},U={find:(t,e=document.documentElement)=>[].concat(...Element.prototype.querySelectorAll.call(e,t)),findOne:(t,e=document.documentElement)=>Element.prototype.querySelector.call(e,t),children:(t,e)=>[].concat(...t.children).filter(t=>t.matches(e)),parents(t,e){const i=[];let n=t.parentNode;for(;n&&n.nodeType===Node.ELEMENT_NODE&&3!==n.nodeType;)n.matches(e)&&i.push(n),n=n.parentNode;return i},prev(t,e){let i=t.previousElementSibling;for(;i;){if(i.matches(e))return[i];i=i.previousElementSibling}return[]},next(t,e){let i=t.nextElementSibling;for(;i;){if(i.matches(e))return[i];i=i.nextElementSibling}return[]},focusableChildren(t){const e=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map(t=>t+':not([tabindex^="-"])').join(", ");return this.find(e,t).filter(t=>!l(t)&&a(t))}},$={interval:5e3,keyboard:!0,slide:!1,pause:"hover",wrap:!0,touch:!0},V={interval:"(number|boolean)",keyboard:"boolean",slide:"(boolean|string)",pause:"(string|boolean)",wrap:"boolean",touch:"boolean"},K="next",X="prev",Y="left",Q="right",G={ArrowLeft:Q,ArrowRight:Y};class Z extends H{constructor(t,e){super(t),this._items=null,this._interval=null,this._activeElement=null,this._isPaused=!1,this._isSliding=!1,this.touchTimeout=null,this.touchStartX=0,this.touchDeltaX=0,this._config=this._getConfig(e),this._indicatorsElement=U.findOne(".carousel-indicators",this._element),this._touchSupported="ontouchstart"in document.documentElement||navigator.maxTouchPoints>0,this._pointerEvent=Boolean(window.PointerEvent),this._addEventListeners()}static get Default(){return $}static get NAME(){return"carousel"}next(){this._slide(K)}nextWhenVisible(){!document.hidden&&a(this._element)&&this.next()}prev(){this._slide(X)}pause(t){t||(this._isPaused=!0),U.findOne(".carousel-item-next, .carousel-item-prev",this._element)&&(n(this._element),this.cycle(!0)),clearInterval(this._interval),this._interval=null}cycle(t){t||(this._isPaused=!1),this._interval&&(clearInterval(this._interval),this._interval=null),this._config&&this._config.interval&&!this._isPaused&&(this._updateInterval(),this._interval=setInterval((document.visibilityState?this.nextWhenVisible:this.next).bind(this),this._config.interval))}to(t){this._activeElement=U.findOne(".active.carousel-item",this._element);const e=this._getItemIndex(this._activeElement);if(t>this._items.length-1||t<0)return;if(this._isSliding)return void P.one(this._element,"slid.bs.carousel",()=>this.to(t));if(e===t)return this.pause(),void this.cycle();const i=t>e?K:X;this._slide(i,this._items[t])}_getConfig(t){return t={...$,...F.getDataAttributes(this._element),..."object"==typeof t?t:{}},r("carousel",t,V),t}_handleSwipe(){const t=Math.abs(this.touchDeltaX);if(t<=40)return;const e=t/this.touchDeltaX;this.touchDeltaX=0,e&&this._slide(e>0?Q:Y)}_addEventListeners(){this._config.keyboard&&P.on(this._element,"keydown.bs.carousel",t=>this._keydown(t)),"hover"===this._config.pause&&(P.on(this._element,"mouseenter.bs.carousel",t=>this.pause(t)),P.on(this._element,"mouseleave.bs.carousel",t=>this.cycle(t))),this._config.touch&&this._touchSupported&&this._addTouchEventListeners()}_addTouchEventListeners(){const t=t=>this._pointerEvent&&("pen"===t.pointerType||"touch"===t.pointerType),e=e=>{t(e)?this.touchStartX=e.clientX:this._pointerEvent||(this.touchStartX=e.touches[0].clientX)},i=t=>{this.touchDeltaX=t.touches&&t.touches.length>1?0:t.touches[0].clientX-this.touchStartX},n=e=>{t(e)&&(this.touchDeltaX=e.clientX-this.touchStartX),this._handleSwipe(),"hover"===this._config.pause&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout(t=>this.cycle(t),500+this._config.interval))};U.find(".carousel-item img",this._element).forEach(t=>{P.on(t,"dragstart.bs.carousel",t=>t.preventDefault())}),this._pointerEvent?(P.on(this._element,"pointerdown.bs.carousel",t=>e(t)),P.on(this._element,"pointerup.bs.carousel",t=>n(t)),this._element.classList.add("pointer-event")):(P.on(this._element,"touchstart.bs.carousel",t=>e(t)),P.on(this._element,"touchmove.bs.carousel",t=>i(t)),P.on(this._element,"touchend.bs.carousel",t=>n(t)))}_keydown(t){if(/input|textarea/i.test(t.target.tagName))return;const e=G[t.key];e&&(t.preventDefault(),this._slide(e))}_getItemIndex(t){return this._items=t&&t.parentNode?U.find(".carousel-item",t.parentNode):[],this._items.indexOf(t)}_getItemByOrder(t,e){const i=t===K;return b(this._items,e,i,this._config.wrap)}_triggerSlideEvent(t,e){const i=this._getItemIndex(t),n=this._getItemIndex(U.findOne(".active.carousel-item",this._element));return P.trigger(this._element,"slide.bs.carousel",{relatedTarget:t,direction:e,from:n,to:i})}_setActiveIndicatorElement(t){if(this._indicatorsElement){const e=U.findOne(".active",this._indicatorsElement);e.classList.remove("active"),e.removeAttribute("aria-current");const i=U.find("[data-bs-target]",this._indicatorsElement);for(let e=0;e{P.trigger(this._element,"slid.bs.carousel",{relatedTarget:o,direction:u,from:s,to:r})};if(this._element.classList.contains("slide")){o.classList.add(h),d(o),n.classList.add(c),o.classList.add(c);const t=()=>{o.classList.remove(c,h),o.classList.add("active"),n.classList.remove("active",h,c),this._isSliding=!1,setTimeout(f,0)};this._queueCallback(t,n,!0)}else n.classList.remove("active"),o.classList.add("active"),this._isSliding=!1,f();a&&this.cycle()}_directionToOrder(t){return[Q,Y].includes(t)?p()?t===Y?X:K:t===Y?K:X:t}_orderToDirection(t){return[K,X].includes(t)?p()?t===X?Y:Q:t===X?Q:Y:t}static carouselInterface(t,e){const i=Z.getOrCreateInstance(t,e);let{_config:n}=i;"object"==typeof e&&(n={...n,...e});const s="string"==typeof e?e:n.slide;if("number"==typeof e)i.to(e);else if("string"==typeof s){if(void 0===i[s])throw new TypeError(`No method named "${s}"`);i[s]()}else n.interval&&n.ride&&(i.pause(),i.cycle())}static jQueryInterface(t){return this.each((function(){Z.carouselInterface(this,t)}))}static dataApiClickHandler(t){const e=i(this);if(!e||!e.classList.contains("carousel"))return;const n={...F.getDataAttributes(e),...F.getDataAttributes(this)},s=this.getAttribute("data-bs-slide-to");s&&(n.interval=!1),Z.carouselInterface(e,n),s&&Z.getInstance(e).to(s),t.preventDefault()}}P.on(document,"click.bs.carousel.data-api","[data-bs-slide], [data-bs-slide-to]",Z.dataApiClickHandler),P.on(window,"load.bs.carousel.data-api",()=>{const t=U.find('[data-bs-ride="carousel"]');for(let e=0,i=t.length;et===this._element);null!==s&&o.length&&(this._selector=s,this._triggerArray.push(i))}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return J}static get NAME(){return"collapse"}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let t,e=[];if(this._config.parent){const t=U.find(".collapse .collapse",this._config.parent);e=U.find(".collapse.show, .collapse.collapsing",this._config.parent).filter(e=>!t.includes(e))}const i=U.findOne(this._selector);if(e.length){const n=e.find(t=>i!==t);if(t=n?et.getInstance(n):null,t&&t._isTransitioning)return}if(P.trigger(this._element,"show.bs.collapse").defaultPrevented)return;e.forEach(e=>{i!==e&&et.getOrCreateInstance(e,{toggle:!1}).hide(),t||M.set(e,"bs.collapse",null)});const n=this._getDimension();this._element.classList.remove("collapse"),this._element.classList.add("collapsing"),this._element.style[n]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const s="scroll"+(n[0].toUpperCase()+n.slice(1));this._queueCallback(()=>{this._isTransitioning=!1,this._element.classList.remove("collapsing"),this._element.classList.add("collapse","show"),this._element.style[n]="",P.trigger(this._element,"shown.bs.collapse")},this._element,!0),this._element.style[n]=this._element[s]+"px"}hide(){if(this._isTransitioning||!this._isShown())return;if(P.trigger(this._element,"hide.bs.collapse").defaultPrevented)return;const t=this._getDimension();this._element.style[t]=this._element.getBoundingClientRect()[t]+"px",d(this._element),this._element.classList.add("collapsing"),this._element.classList.remove("collapse","show");const e=this._triggerArray.length;for(let t=0;t{this._isTransitioning=!1,this._element.classList.remove("collapsing"),this._element.classList.add("collapse"),P.trigger(this._element,"hidden.bs.collapse")},this._element,!0)}_isShown(t=this._element){return t.classList.contains("show")}_getConfig(t){return(t={...J,...F.getDataAttributes(this._element),...t}).toggle=Boolean(t.toggle),t.parent=o(t.parent),r("collapse",t,tt),t}_getDimension(){return this._element.classList.contains("collapse-horizontal")?"width":"height"}_initializeChildren(){if(!this._config.parent)return;const t=U.find(".collapse .collapse",this._config.parent);U.find('[data-bs-toggle="collapse"]',this._config.parent).filter(e=>!t.includes(e)).forEach(t=>{const e=i(t);e&&this._addAriaAndCollapsedClass([t],this._isShown(e))})}_addAriaAndCollapsedClass(t,e){t.length&&t.forEach(t=>{e?t.classList.remove("collapsed"):t.classList.add("collapsed"),t.setAttribute("aria-expanded",e)})}static jQueryInterface(t){return this.each((function(){const e={};"string"==typeof t&&/show|hide/.test(t)&&(e.toggle=!1);const i=et.getOrCreateInstance(this,e);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}))}}P.on(document,"click.bs.collapse.data-api",'[data-bs-toggle="collapse"]',(function(t){("A"===t.target.tagName||t.delegateTarget&&"A"===t.delegateTarget.tagName)&&t.preventDefault();const i=e(this);U.find(i).forEach(t=>{et.getOrCreateInstance(t,{toggle:!1}).toggle()})})),m(et);var it="top",nt="bottom",st="right",ot="left",rt=[it,nt,st,ot],at="end",lt=rt.reduce((function(t,e){return t.concat([e+"-start",e+"-"+at])}),[]),ct=[].concat(rt,["auto"]).reduce((function(t,e){return t.concat([e,e+"-start",e+"-"+at])}),[]),ht=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function dt(t){return t?(t.nodeName||"").toLowerCase():null}function ut(t){if(null==t)return window;if("[object Window]"!==t.toString()){var e=t.ownerDocument;return e&&e.defaultView||window}return t}function ft(t){return t instanceof ut(t).Element||t instanceof Element}function pt(t){return t instanceof ut(t).HTMLElement||t instanceof HTMLElement}function mt(t){return"undefined"!=typeof ShadowRoot&&(t instanceof ut(t).ShadowRoot||t instanceof ShadowRoot)}var gt={name:"applyStyles",enabled:!0,phase:"write",fn:function(t){var e=t.state;Object.keys(e.elements).forEach((function(t){var i=e.styles[t]||{},n=e.attributes[t]||{},s=e.elements[t];pt(s)&&dt(s)&&(Object.assign(s.style,i),Object.keys(n).forEach((function(t){var e=n[t];!1===e?s.removeAttribute(t):s.setAttribute(t,!0===e?"":e)})))}))},effect:function(t){var e=t.state,i={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(e.elements.popper.style,i.popper),e.styles=i,e.elements.arrow&&Object.assign(e.elements.arrow.style,i.arrow),function(){Object.keys(e.elements).forEach((function(t){var n=e.elements[t],s=e.attributes[t]||{},o=Object.keys(e.styles.hasOwnProperty(t)?e.styles[t]:i[t]).reduce((function(t,e){return t[e]="",t}),{});pt(n)&&dt(n)&&(Object.assign(n.style,o),Object.keys(s).forEach((function(t){n.removeAttribute(t)})))}))}},requires:["computeStyles"]};function _t(t){return t.split("-")[0]}var bt=Math.round;function vt(t,e){void 0===e&&(e=!1);var i=t.getBoundingClientRect(),n=1,s=1;if(pt(t)&&e){var o=t.offsetHeight,r=t.offsetWidth;r>0&&(n=i.width/r||1),o>0&&(s=i.height/o||1)}return{width:bt(i.width/n),height:bt(i.height/s),top:bt(i.top/s),right:bt(i.right/n),bottom:bt(i.bottom/s),left:bt(i.left/n),x:bt(i.left/n),y:bt(i.top/s)}}function yt(t){var e=vt(t),i=t.offsetWidth,n=t.offsetHeight;return Math.abs(e.width-i)<=1&&(i=e.width),Math.abs(e.height-n)<=1&&(n=e.height),{x:t.offsetLeft,y:t.offsetTop,width:i,height:n}}function wt(t,e){var i=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(i&&mt(i)){var n=e;do{if(n&&t.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function Et(t){return ut(t).getComputedStyle(t)}function At(t){return["table","td","th"].indexOf(dt(t))>=0}function Tt(t){return((ft(t)?t.ownerDocument:t.document)||window.document).documentElement}function Ot(t){return"html"===dt(t)?t:t.assignedSlot||t.parentNode||(mt(t)?t.host:null)||Tt(t)}function Ct(t){return pt(t)&&"fixed"!==Et(t).position?t.offsetParent:null}function kt(t){for(var e=ut(t),i=Ct(t);i&&At(i)&&"static"===Et(i).position;)i=Ct(i);return i&&("html"===dt(i)||"body"===dt(i)&&"static"===Et(i).position)?e:i||function(t){var e=-1!==navigator.userAgent.toLowerCase().indexOf("firefox");if(-1!==navigator.userAgent.indexOf("Trident")&&pt(t)&&"fixed"===Et(t).position)return null;for(var i=Ot(t);pt(i)&&["html","body"].indexOf(dt(i))<0;){var n=Et(i);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||e&&"filter"===n.willChange||e&&n.filter&&"none"!==n.filter)return i;i=i.parentNode}return null}(t)||e}function Lt(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}var xt=Math.max,Dt=Math.min,St=Math.round;function Nt(t,e,i){return xt(t,Dt(e,i))}function It(t){return Object.assign({},{top:0,right:0,bottom:0,left:0},t)}function Pt(t,e){return e.reduce((function(e,i){return e[i]=t,e}),{})}var jt={name:"arrow",enabled:!0,phase:"main",fn:function(t){var e,i=t.state,n=t.name,s=t.options,o=i.elements.arrow,r=i.modifiersData.popperOffsets,a=_t(i.placement),l=Lt(a),c=[ot,st].indexOf(a)>=0?"height":"width";if(o&&r){var h=function(t,e){return It("number"!=typeof(t="function"==typeof t?t(Object.assign({},e.rects,{placement:e.placement})):t)?t:Pt(t,rt))}(s.padding,i),d=yt(o),u="y"===l?it:ot,f="y"===l?nt:st,p=i.rects.reference[c]+i.rects.reference[l]-r[l]-i.rects.popper[c],m=r[l]-i.rects.reference[l],g=kt(o),_=g?"y"===l?g.clientHeight||0:g.clientWidth||0:0,b=p/2-m/2,v=h[u],y=_-d[c]-h[f],w=_/2-d[c]/2+b,E=Nt(v,w,y),A=l;i.modifiersData[n]=((e={})[A]=E,e.centerOffset=E-w,e)}},effect:function(t){var e=t.state,i=t.options.element,n=void 0===i?"[data-popper-arrow]":i;null!=n&&("string"!=typeof n||(n=e.elements.popper.querySelector(n)))&&wt(e.elements.popper,n)&&(e.elements.arrow=n)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Mt(t){return t.split("-")[1]}var Ht={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Bt(t){var e,i=t.popper,n=t.popperRect,s=t.placement,o=t.variation,r=t.offsets,a=t.position,l=t.gpuAcceleration,c=t.adaptive,h=t.roundOffsets,d=!0===h?function(t){var e=t.x,i=t.y,n=window.devicePixelRatio||1;return{x:St(St(e*n)/n)||0,y:St(St(i*n)/n)||0}}(r):"function"==typeof h?h(r):r,u=d.x,f=void 0===u?0:u,p=d.y,m=void 0===p?0:p,g=r.hasOwnProperty("x"),_=r.hasOwnProperty("y"),b=ot,v=it,y=window;if(c){var w=kt(i),E="clientHeight",A="clientWidth";w===ut(i)&&"static"!==Et(w=Tt(i)).position&&"absolute"===a&&(E="scrollHeight",A="scrollWidth"),w=w,s!==it&&(s!==ot&&s!==st||o!==at)||(v=nt,m-=w[E]-n.height,m*=l?1:-1),s!==ot&&(s!==it&&s!==nt||o!==at)||(b=st,f-=w[A]-n.width,f*=l?1:-1)}var T,O=Object.assign({position:a},c&&Ht);return l?Object.assign({},O,((T={})[v]=_?"0":"",T[b]=g?"0":"",T.transform=(y.devicePixelRatio||1)<=1?"translate("+f+"px, "+m+"px)":"translate3d("+f+"px, "+m+"px, 0)",T)):Object.assign({},O,((e={})[v]=_?m+"px":"",e[b]=g?f+"px":"",e.transform="",e))}var Rt={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(t){var e=t.state,i=t.options,n=i.gpuAcceleration,s=void 0===n||n,o=i.adaptive,r=void 0===o||o,a=i.roundOffsets,l=void 0===a||a,c={placement:_t(e.placement),variation:Mt(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:s};null!=e.modifiersData.popperOffsets&&(e.styles.popper=Object.assign({},e.styles.popper,Bt(Object.assign({},c,{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:r,roundOffsets:l})))),null!=e.modifiersData.arrow&&(e.styles.arrow=Object.assign({},e.styles.arrow,Bt(Object.assign({},c,{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-placement":e.placement})},data:{}},Wt={passive:!0},zt={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(t){var e=t.state,i=t.instance,n=t.options,s=n.scroll,o=void 0===s||s,r=n.resize,a=void 0===r||r,l=ut(e.elements.popper),c=[].concat(e.scrollParents.reference,e.scrollParents.popper);return o&&c.forEach((function(t){t.addEventListener("scroll",i.update,Wt)})),a&&l.addEventListener("resize",i.update,Wt),function(){o&&c.forEach((function(t){t.removeEventListener("scroll",i.update,Wt)})),a&&l.removeEventListener("resize",i.update,Wt)}},data:{}},qt={left:"right",right:"left",bottom:"top",top:"bottom"};function Ft(t){return t.replace(/left|right|bottom|top/g,(function(t){return qt[t]}))}var Ut={start:"end",end:"start"};function $t(t){return t.replace(/start|end/g,(function(t){return Ut[t]}))}function Vt(t){var e=ut(t);return{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function Kt(t){return vt(Tt(t)).left+Vt(t).scrollLeft}function Xt(t){var e=Et(t),i=e.overflow,n=e.overflowX,s=e.overflowY;return/auto|scroll|overlay|hidden/.test(i+s+n)}function Yt(t,e){var i;void 0===e&&(e=[]);var n=function t(e){return["html","body","#document"].indexOf(dt(e))>=0?e.ownerDocument.body:pt(e)&&Xt(e)?e:t(Ot(e))}(t),s=n===(null==(i=t.ownerDocument)?void 0:i.body),o=ut(n),r=s?[o].concat(o.visualViewport||[],Xt(n)?n:[]):n,a=e.concat(r);return s?a:a.concat(Yt(Ot(r)))}function Qt(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function Gt(t,e){return"viewport"===e?Qt(function(t){var e=ut(t),i=Tt(t),n=e.visualViewport,s=i.clientWidth,o=i.clientHeight,r=0,a=0;return n&&(s=n.width,o=n.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(r=n.offsetLeft,a=n.offsetTop)),{width:s,height:o,x:r+Kt(t),y:a}}(t)):pt(e)?function(t){var e=vt(t);return e.top=e.top+t.clientTop,e.left=e.left+t.clientLeft,e.bottom=e.top+t.clientHeight,e.right=e.left+t.clientWidth,e.width=t.clientWidth,e.height=t.clientHeight,e.x=e.left,e.y=e.top,e}(e):Qt(function(t){var e,i=Tt(t),n=Vt(t),s=null==(e=t.ownerDocument)?void 0:e.body,o=xt(i.scrollWidth,i.clientWidth,s?s.scrollWidth:0,s?s.clientWidth:0),r=xt(i.scrollHeight,i.clientHeight,s?s.scrollHeight:0,s?s.clientHeight:0),a=-n.scrollLeft+Kt(t),l=-n.scrollTop;return"rtl"===Et(s||i).direction&&(a+=xt(i.clientWidth,s?s.clientWidth:0)-o),{width:o,height:r,x:a,y:l}}(Tt(t)))}function Zt(t){var e,i=t.reference,n=t.element,s=t.placement,o=s?_t(s):null,r=s?Mt(s):null,a=i.x+i.width/2-n.width/2,l=i.y+i.height/2-n.height/2;switch(o){case it:e={x:a,y:i.y-n.height};break;case nt:e={x:a,y:i.y+i.height};break;case st:e={x:i.x+i.width,y:l};break;case ot:e={x:i.x-n.width,y:l};break;default:e={x:i.x,y:i.y}}var c=o?Lt(o):null;if(null!=c){var h="y"===c?"height":"width";switch(r){case"start":e[c]=e[c]-(i[h]/2-n[h]/2);break;case at:e[c]=e[c]+(i[h]/2-n[h]/2)}}return e}function Jt(t,e){void 0===e&&(e={});var i=e,n=i.placement,s=void 0===n?t.placement:n,o=i.boundary,r=void 0===o?"clippingParents":o,a=i.rootBoundary,l=void 0===a?"viewport":a,c=i.elementContext,h=void 0===c?"popper":c,d=i.altBoundary,u=void 0!==d&&d,f=i.padding,p=void 0===f?0:f,m=It("number"!=typeof p?p:Pt(p,rt)),g="popper"===h?"reference":"popper",_=t.rects.popper,b=t.elements[u?g:h],v=function(t,e,i){var n="clippingParents"===e?function(t){var e=Yt(Ot(t)),i=["absolute","fixed"].indexOf(Et(t).position)>=0&&pt(t)?kt(t):t;return ft(i)?e.filter((function(t){return ft(t)&&wt(t,i)&&"body"!==dt(t)})):[]}(t):[].concat(e),s=[].concat(n,[i]),o=s[0],r=s.reduce((function(e,i){var n=Gt(t,i);return e.top=xt(n.top,e.top),e.right=Dt(n.right,e.right),e.bottom=Dt(n.bottom,e.bottom),e.left=xt(n.left,e.left),e}),Gt(t,o));return r.width=r.right-r.left,r.height=r.bottom-r.top,r.x=r.left,r.y=r.top,r}(ft(b)?b:b.contextElement||Tt(t.elements.popper),r,l),y=vt(t.elements.reference),w=Zt({reference:y,element:_,strategy:"absolute",placement:s}),E=Qt(Object.assign({},_,w)),A="popper"===h?E:y,T={top:v.top-A.top+m.top,bottom:A.bottom-v.bottom+m.bottom,left:v.left-A.left+m.left,right:A.right-v.right+m.right},O=t.modifiersData.offset;if("popper"===h&&O){var C=O[s];Object.keys(T).forEach((function(t){var e=[st,nt].indexOf(t)>=0?1:-1,i=[it,nt].indexOf(t)>=0?"y":"x";T[t]+=C[i]*e}))}return T}function te(t,e){void 0===e&&(e={});var i=e,n=i.placement,s=i.boundary,o=i.rootBoundary,r=i.padding,a=i.flipVariations,l=i.allowedAutoPlacements,c=void 0===l?ct:l,h=Mt(n),d=h?a?lt:lt.filter((function(t){return Mt(t)===h})):rt,u=d.filter((function(t){return c.indexOf(t)>=0}));0===u.length&&(u=d);var f=u.reduce((function(e,i){return e[i]=Jt(t,{placement:i,boundary:s,rootBoundary:o,padding:r})[_t(i)],e}),{});return Object.keys(f).sort((function(t,e){return f[t]-f[e]}))}var ee={name:"flip",enabled:!0,phase:"main",fn:function(t){var e=t.state,i=t.options,n=t.name;if(!e.modifiersData[n]._skip){for(var s=i.mainAxis,o=void 0===s||s,r=i.altAxis,a=void 0===r||r,l=i.fallbackPlacements,c=i.padding,h=i.boundary,d=i.rootBoundary,u=i.altBoundary,f=i.flipVariations,p=void 0===f||f,m=i.allowedAutoPlacements,g=e.options.placement,_=_t(g),b=l||(_!==g&&p?function(t){if("auto"===_t(t))return[];var e=Ft(t);return[$t(t),e,$t(e)]}(g):[Ft(g)]),v=[g].concat(b).reduce((function(t,i){return t.concat("auto"===_t(i)?te(e,{placement:i,boundary:h,rootBoundary:d,padding:c,flipVariations:p,allowedAutoPlacements:m}):i)}),[]),y=e.rects.reference,w=e.rects.popper,E=new Map,A=!0,T=v[0],O=0;O=0,D=x?"width":"height",S=Jt(e,{placement:C,boundary:h,rootBoundary:d,altBoundary:u,padding:c}),N=x?L?st:ot:L?nt:it;y[D]>w[D]&&(N=Ft(N));var I=Ft(N),P=[];if(o&&P.push(S[k]<=0),a&&P.push(S[N]<=0,S[I]<=0),P.every((function(t){return t}))){T=C,A=!1;break}E.set(C,P)}if(A)for(var j=function(t){var e=v.find((function(e){var i=E.get(e);if(i)return i.slice(0,t).every((function(t){return t}))}));if(e)return T=e,"break"},M=p?3:1;M>0&&"break"!==j(M);M--);e.placement!==T&&(e.modifiersData[n]._skip=!0,e.placement=T,e.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function ie(t,e,i){return void 0===i&&(i={x:0,y:0}),{top:t.top-e.height-i.y,right:t.right-e.width+i.x,bottom:t.bottom-e.height+i.y,left:t.left-e.width-i.x}}function ne(t){return[it,st,nt,ot].some((function(e){return t[e]>=0}))}var se={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(t){var e=t.state,i=t.name,n=e.rects.reference,s=e.rects.popper,o=e.modifiersData.preventOverflow,r=Jt(e,{elementContext:"reference"}),a=Jt(e,{altBoundary:!0}),l=ie(r,n),c=ie(a,s,o),h=ne(l),d=ne(c);e.modifiersData[i]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:h,hasPopperEscaped:d},e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-reference-hidden":h,"data-popper-escaped":d})}},oe={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(t){var e=t.state,i=t.options,n=t.name,s=i.offset,o=void 0===s?[0,0]:s,r=ct.reduce((function(t,i){return t[i]=function(t,e,i){var n=_t(t),s=[ot,it].indexOf(n)>=0?-1:1,o="function"==typeof i?i(Object.assign({},e,{placement:t})):i,r=o[0],a=o[1];return r=r||0,a=(a||0)*s,[ot,st].indexOf(n)>=0?{x:a,y:r}:{x:r,y:a}}(i,e.rects,o),t}),{}),a=r[e.placement],l=a.x,c=a.y;null!=e.modifiersData.popperOffsets&&(e.modifiersData.popperOffsets.x+=l,e.modifiersData.popperOffsets.y+=c),e.modifiersData[n]=r}},re={name:"popperOffsets",enabled:!0,phase:"read",fn:function(t){var e=t.state,i=t.name;e.modifiersData[i]=Zt({reference:e.rects.reference,element:e.rects.popper,strategy:"absolute",placement:e.placement})},data:{}},ae={name:"preventOverflow",enabled:!0,phase:"main",fn:function(t){var e=t.state,i=t.options,n=t.name,s=i.mainAxis,o=void 0===s||s,r=i.altAxis,a=void 0!==r&&r,l=i.boundary,c=i.rootBoundary,h=i.altBoundary,d=i.padding,u=i.tether,f=void 0===u||u,p=i.tetherOffset,m=void 0===p?0:p,g=Jt(e,{boundary:l,rootBoundary:c,padding:d,altBoundary:h}),_=_t(e.placement),b=Mt(e.placement),v=!b,y=Lt(_),w="x"===y?"y":"x",E=e.modifiersData.popperOffsets,A=e.rects.reference,T=e.rects.popper,O="function"==typeof m?m(Object.assign({},e.rects,{placement:e.placement})):m,C={x:0,y:0};if(E){if(o||a){var k="y"===y?it:ot,L="y"===y?nt:st,x="y"===y?"height":"width",D=E[y],S=E[y]+g[k],N=E[y]-g[L],I=f?-T[x]/2:0,P="start"===b?A[x]:T[x],j="start"===b?-T[x]:-A[x],M=e.elements.arrow,H=f&&M?yt(M):{width:0,height:0},B=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},R=B[k],W=B[L],z=Nt(0,A[x],H[x]),q=v?A[x]/2-I-z-R-O:P-z-R-O,F=v?-A[x]/2+I+z+W+O:j+z+W+O,U=e.elements.arrow&&kt(e.elements.arrow),$=U?"y"===y?U.clientTop||0:U.clientLeft||0:0,V=e.modifiersData.offset?e.modifiersData.offset[e.placement][y]:0,K=E[y]+q-V-$,X=E[y]+F-V;if(o){var Y=Nt(f?Dt(S,K):S,D,f?xt(N,X):N);E[y]=Y,C[y]=Y-D}if(a){var Q="x"===y?it:ot,G="x"===y?nt:st,Z=E[w],J=Z+g[Q],tt=Z-g[G],et=Nt(f?Dt(J,K):J,Z,f?xt(tt,X):tt);E[w]=et,C[w]=et-Z}}e.modifiersData[n]=C}},requiresIfExists:["offset"]};function le(t,e,i){void 0===i&&(i=!1);var n,s,o=pt(e),r=pt(e)&&function(t){var e=t.getBoundingClientRect(),i=e.width/t.offsetWidth||1,n=e.height/t.offsetHeight||1;return 1!==i||1!==n}(e),a=Tt(e),l=vt(t,r),c={scrollLeft:0,scrollTop:0},h={x:0,y:0};return(o||!o&&!i)&&(("body"!==dt(e)||Xt(a))&&(c=(n=e)!==ut(n)&&pt(n)?{scrollLeft:(s=n).scrollLeft,scrollTop:s.scrollTop}:Vt(n)),pt(e)?((h=vt(e,!0)).x+=e.clientLeft,h.y+=e.clientTop):a&&(h.x=Kt(a))),{x:l.left+c.scrollLeft-h.x,y:l.top+c.scrollTop-h.y,width:l.width,height:l.height}}var ce={placement:"bottom",modifiers:[],strategy:"absolute"};function he(){for(var t=arguments.length,e=new Array(t),i=0;iP.on(t,"mouseover",h)),this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add("show"),this._element.classList.add("show"),P.trigger(this._element,"shown.bs.dropdown",t)}hide(){if(l(this._element)||!this._isShown(this._menu))return;const t={relatedTarget:this._element};this._completeHide(t)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(t){P.trigger(this._element,"hide.bs.dropdown",t).defaultPrevented||("ontouchstart"in document.documentElement&&[].concat(...document.body.children).forEach(t=>P.off(t,"mouseover",h)),this._popper&&this._popper.destroy(),this._menu.classList.remove("show"),this._element.classList.remove("show"),this._element.setAttribute("aria-expanded","false"),F.removeDataAttribute(this._menu,"popper"),P.trigger(this._element,"hidden.bs.dropdown",t))}_getConfig(t){if(t={...this.constructor.Default,...F.getDataAttributes(this._element),...t},r("dropdown",t,this.constructor.DefaultType),"object"==typeof t.reference&&!s(t.reference)&&"function"!=typeof t.reference.getBoundingClientRect)throw new TypeError("dropdown".toUpperCase()+': Option "reference" provided type "object" without a required "getBoundingClientRect" method.');return t}_createPopper(t){if(void 0===me)throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)");let e=this._element;"parent"===this._config.reference?e=t:s(this._config.reference)?e=o(this._config.reference):"object"==typeof this._config.reference&&(e=this._config.reference);const i=this._getPopperConfig(),n=i.modifiers.find(t=>"applyStyles"===t.name&&!1===t.enabled);this._popper=pe(e,this._menu,i),n&&F.setDataAttribute(this._menu,"popper","static")}_isShown(t=this._element){return t.classList.contains("show")}_getMenuElement(){return U.next(this._element,".dropdown-menu")[0]}_getPlacement(){const t=this._element.parentNode;if(t.classList.contains("dropend"))return we;if(t.classList.contains("dropstart"))return Ee;const e="end"===getComputedStyle(this._menu).getPropertyValue("--bs-position").trim();return t.classList.contains("dropup")?e?be:_e:e?ye:ve}_detectNavbar(){return null!==this._element.closest(".navbar")}_getOffset(){const{offset:t}=this._config;return"string"==typeof t?t.split(",").map(t=>Number.parseInt(t,10)):"function"==typeof t?e=>t(e,this._element):t}_getPopperConfig(){const t={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return"static"===this._config.display&&(t.modifiers=[{name:"applyStyles",enabled:!1}]),{...t,..."function"==typeof this._config.popperConfig?this._config.popperConfig(t):this._config.popperConfig}}_selectMenuItem({key:t,target:e}){const i=U.find(".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",this._menu).filter(a);i.length&&b(i,e,"ArrowDown"===t,!i.includes(e)).focus()}static jQueryInterface(t){return this.each((function(){const e=Oe.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}static clearMenus(t){if(t&&(2===t.button||"keyup"===t.type&&"Tab"!==t.key))return;const e=U.find('[data-bs-toggle="dropdown"]');for(let i=0,n=e.length;ie+t),this._setElementAttributes(".fixed-top, .fixed-bottom, .is-fixed, .sticky-top","paddingRight",e=>e+t),this._setElementAttributes(".sticky-top","marginRight",e=>e-t)}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(t,e,i){const n=this.getWidth();this._applyManipulationCallback(t,t=>{if(t!==this._element&&window.innerWidth>t.clientWidth+n)return;this._saveInitialAttribute(t,e);const s=window.getComputedStyle(t)[e];t.style[e]=i(Number.parseFloat(s))+"px"})}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,"paddingRight"),this._resetElementAttributes(".fixed-top, .fixed-bottom, .is-fixed, .sticky-top","paddingRight"),this._resetElementAttributes(".sticky-top","marginRight")}_saveInitialAttribute(t,e){const i=t.style[e];i&&F.setDataAttribute(t,e,i)}_resetElementAttributes(t,e){this._applyManipulationCallback(t,t=>{const i=F.getDataAttribute(t,e);void 0===i?t.style.removeProperty(e):(F.removeDataAttribute(t,e),t.style[e]=i)})}_applyManipulationCallback(t,e){s(t)?e(t):U.find(t,this._element).forEach(e)}isOverflowing(){return this.getWidth()>0}}const ke={className:"modal-backdrop",isVisible:!0,isAnimated:!1,rootElement:"body",clickCallback:null},Le={className:"string",isVisible:"boolean",isAnimated:"boolean",rootElement:"(element|string)",clickCallback:"(function|null)"};class xe{constructor(t){this._config=this._getConfig(t),this._isAppended=!1,this._element=null}show(t){this._config.isVisible?(this._append(),this._config.isAnimated&&d(this._getElement()),this._getElement().classList.add("show"),this._emulateAnimation(()=>{g(t)})):g(t)}hide(t){this._config.isVisible?(this._getElement().classList.remove("show"),this._emulateAnimation(()=>{this.dispose(),g(t)})):g(t)}_getElement(){if(!this._element){const t=document.createElement("div");t.className=this._config.className,this._config.isAnimated&&t.classList.add("fade"),this._element=t}return this._element}_getConfig(t){return(t={...ke,..."object"==typeof t?t:{}}).rootElement=o(t.rootElement),r("backdrop",t,Le),t}_append(){this._isAppended||(this._config.rootElement.append(this._getElement()),P.on(this._getElement(),"mousedown.bs.backdrop",()=>{g(this._config.clickCallback)}),this._isAppended=!0)}dispose(){this._isAppended&&(P.off(this._element,"mousedown.bs.backdrop"),this._element.remove(),this._isAppended=!1)}_emulateAnimation(t){_(t,this._getElement(),this._config.isAnimated)}}const De={trapElement:null,autofocus:!0},Se={trapElement:"element",autofocus:"boolean"};class Ne{constructor(t){this._config=this._getConfig(t),this._isActive=!1,this._lastTabNavDirection=null}activate(){const{trapElement:t,autofocus:e}=this._config;this._isActive||(e&&t.focus(),P.off(document,".bs.focustrap"),P.on(document,"focusin.bs.focustrap",t=>this._handleFocusin(t)),P.on(document,"keydown.tab.bs.focustrap",t=>this._handleKeydown(t)),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,P.off(document,".bs.focustrap"))}_handleFocusin(t){const{target:e}=t,{trapElement:i}=this._config;if(e===document||e===i||i.contains(e))return;const n=U.focusableChildren(i);0===n.length?i.focus():"backward"===this._lastTabNavDirection?n[n.length-1].focus():n[0].focus()}_handleKeydown(t){"Tab"===t.key&&(this._lastTabNavDirection=t.shiftKey?"backward":"forward")}_getConfig(t){return t={...De,..."object"==typeof t?t:{}},r("focustrap",t,Se),t}}const Ie={backdrop:!0,keyboard:!0,focus:!0},Pe={backdrop:"(boolean|string)",keyboard:"boolean",focus:"boolean"};class je extends H{constructor(t,e){super(t),this._config=this._getConfig(e),this._dialog=U.findOne(".modal-dialog",this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._ignoreBackdropClick=!1,this._isTransitioning=!1,this._scrollBar=new Ce}static get Default(){return Ie}static get NAME(){return"modal"}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||this._isTransitioning||P.trigger(this._element,"show.bs.modal",{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._isAnimated()&&(this._isTransitioning=!0),this._scrollBar.hide(),document.body.classList.add("modal-open"),this._adjustDialog(),this._setEscapeEvent(),this._setResizeEvent(),P.on(this._dialog,"mousedown.dismiss.bs.modal",()=>{P.one(this._element,"mouseup.dismiss.bs.modal",t=>{t.target===this._element&&(this._ignoreBackdropClick=!0)})}),this._showBackdrop(()=>this._showElement(t)))}hide(){if(!this._isShown||this._isTransitioning)return;if(P.trigger(this._element,"hide.bs.modal").defaultPrevented)return;this._isShown=!1;const t=this._isAnimated();t&&(this._isTransitioning=!0),this._setEscapeEvent(),this._setResizeEvent(),this._focustrap.deactivate(),this._element.classList.remove("show"),P.off(this._element,"click.dismiss.bs.modal"),P.off(this._dialog,"mousedown.dismiss.bs.modal"),this._queueCallback(()=>this._hideModal(),this._element,t)}dispose(){[window,this._dialog].forEach(t=>P.off(t,".bs.modal")),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new xe({isVisible:Boolean(this._config.backdrop),isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new Ne({trapElement:this._element})}_getConfig(t){return t={...Ie,...F.getDataAttributes(this._element),..."object"==typeof t?t:{}},r("modal",t,Pe),t}_showElement(t){const e=this._isAnimated(),i=U.findOne(".modal-body",this._dialog);this._element.parentNode&&this._element.parentNode.nodeType===Node.ELEMENT_NODE||document.body.append(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.scrollTop=0,i&&(i.scrollTop=0),e&&d(this._element),this._element.classList.add("show"),this._queueCallback(()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,P.trigger(this._element,"shown.bs.modal",{relatedTarget:t})},this._dialog,e)}_setEscapeEvent(){this._isShown?P.on(this._element,"keydown.dismiss.bs.modal",t=>{this._config.keyboard&&"Escape"===t.key?(t.preventDefault(),this.hide()):this._config.keyboard||"Escape"!==t.key||this._triggerBackdropTransition()}):P.off(this._element,"keydown.dismiss.bs.modal")}_setResizeEvent(){this._isShown?P.on(window,"resize.bs.modal",()=>this._adjustDialog()):P.off(window,"resize.bs.modal")}_hideModal(){this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._isTransitioning=!1,this._backdrop.hide(()=>{document.body.classList.remove("modal-open"),this._resetAdjustments(),this._scrollBar.reset(),P.trigger(this._element,"hidden.bs.modal")})}_showBackdrop(t){P.on(this._element,"click.dismiss.bs.modal",t=>{this._ignoreBackdropClick?this._ignoreBackdropClick=!1:t.target===t.currentTarget&&(!0===this._config.backdrop?this.hide():"static"===this._config.backdrop&&this._triggerBackdropTransition())}),this._backdrop.show(t)}_isAnimated(){return this._element.classList.contains("fade")}_triggerBackdropTransition(){if(P.trigger(this._element,"hidePrevented.bs.modal").defaultPrevented)return;const{classList:t,scrollHeight:e,style:i}=this._element,n=e>document.documentElement.clientHeight;!n&&"hidden"===i.overflowY||t.contains("modal-static")||(n||(i.overflowY="hidden"),t.add("modal-static"),this._queueCallback(()=>{t.remove("modal-static"),n||this._queueCallback(()=>{i.overflowY=""},this._dialog)},this._dialog),this._element.focus())}_adjustDialog(){const t=this._element.scrollHeight>document.documentElement.clientHeight,e=this._scrollBar.getWidth(),i=e>0;(!i&&t&&!p()||i&&!t&&p())&&(this._element.style.paddingLeft=e+"px"),(i&&!t&&!p()||!i&&t&&p())&&(this._element.style.paddingRight=e+"px")}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(t,e){return this.each((function(){const i=je.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t](e)}}))}}P.on(document,"click.bs.modal.data-api",'[data-bs-toggle="modal"]',(function(t){const e=i(this);["A","AREA"].includes(this.tagName)&&t.preventDefault(),P.one(e,"show.bs.modal",t=>{t.defaultPrevented||P.one(e,"hidden.bs.modal",()=>{a(this)&&this.focus()})});const n=U.findOne(".modal.show");n&&je.getInstance(n).hide(),je.getOrCreateInstance(e).toggle(this)})),B(je),m(je);const Me={backdrop:!0,keyboard:!0,scroll:!1},He={backdrop:"boolean",keyboard:"boolean",scroll:"boolean"};class Be extends H{constructor(t,e){super(t),this._config=this._getConfig(e),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get NAME(){return"offcanvas"}static get Default(){return Me}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||P.trigger(this._element,"show.bs.offcanvas",{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._element.style.visibility="visible",this._backdrop.show(),this._config.scroll||(new Ce).hide(),this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add("show"),this._queueCallback(()=>{this._config.scroll||this._focustrap.activate(),P.trigger(this._element,"shown.bs.offcanvas",{relatedTarget:t})},this._element,!0))}hide(){this._isShown&&(P.trigger(this._element,"hide.bs.offcanvas").defaultPrevented||(this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.remove("show"),this._backdrop.hide(),this._queueCallback(()=>{this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._element.style.visibility="hidden",this._config.scroll||(new Ce).reset(),P.trigger(this._element,"hidden.bs.offcanvas")},this._element,!0)))}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_getConfig(t){return t={...Me,...F.getDataAttributes(this._element),..."object"==typeof t?t:{}},r("offcanvas",t,He),t}_initializeBackDrop(){return new xe({className:"offcanvas-backdrop",isVisible:this._config.backdrop,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:()=>this.hide()})}_initializeFocusTrap(){return new Ne({trapElement:this._element})}_addEventListeners(){P.on(this._element,"keydown.dismiss.bs.offcanvas",t=>{this._config.keyboard&&"Escape"===t.key&&this.hide()})}static jQueryInterface(t){return this.each((function(){const e=Be.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}P.on(document,"click.bs.offcanvas.data-api",'[data-bs-toggle="offcanvas"]',(function(t){const e=i(this);if(["A","AREA"].includes(this.tagName)&&t.preventDefault(),l(this))return;P.one(e,"hidden.bs.offcanvas",()=>{a(this)&&this.focus()});const n=U.findOne(".offcanvas.show");n&&n!==e&&Be.getInstance(n).hide(),Be.getOrCreateInstance(e).toggle(this)})),P.on(window,"load.bs.offcanvas.data-api",()=>U.find(".offcanvas.show").forEach(t=>Be.getOrCreateInstance(t).show())),B(Be),m(Be);const Re=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),We=/^(?:(?:https?|mailto|ftp|tel|file):|[^#&/:?]*(?:[#/?]|$))/i,ze=/^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[\d+/a-z]+=*$/i,qe=(t,e)=>{const i=t.nodeName.toLowerCase();if(e.includes(i))return!Re.has(i)||Boolean(We.test(t.nodeValue)||ze.test(t.nodeValue));const n=e.filter(t=>t instanceof RegExp);for(let t=0,e=n.length;t{qe(t,a)||i.removeAttribute(t.nodeName)})}return n.body.innerHTML}const Ue=new Set(["sanitize","allowList","sanitizeFn"]),$e={animation:"boolean",template:"string",title:"(string|element|function)",trigger:"string",delay:"(number|object)",html:"boolean",selector:"(string|boolean)",placement:"(string|function)",offset:"(array|string|function)",container:"(string|element|boolean)",fallbackPlacements:"array",boundary:"(string|element)",customClass:"(string|function)",sanitize:"boolean",sanitizeFn:"(null|function)",allowList:"object",popperConfig:"(null|object|function)"},Ve={AUTO:"auto",TOP:"top",RIGHT:p()?"left":"right",BOTTOM:"bottom",LEFT:p()?"right":"left"},Ke={animation:!0,template:'',trigger:"hover focus",title:"",delay:0,html:!1,selector:!1,placement:"top",offset:[0,0],container:!1,fallbackPlacements:["top","right","bottom","left"],boundary:"clippingParents",customClass:"",sanitize:!0,sanitizeFn:null,allowList:{"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},popperConfig:null},Xe={HIDE:"hide.bs.tooltip",HIDDEN:"hidden.bs.tooltip",SHOW:"show.bs.tooltip",SHOWN:"shown.bs.tooltip",INSERTED:"inserted.bs.tooltip",CLICK:"click.bs.tooltip",FOCUSIN:"focusin.bs.tooltip",FOCUSOUT:"focusout.bs.tooltip",MOUSEENTER:"mouseenter.bs.tooltip",MOUSELEAVE:"mouseleave.bs.tooltip"};class Ye extends H{constructor(t,e){if(void 0===me)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(t),this._isEnabled=!0,this._timeout=0,this._hoverState="",this._activeTrigger={},this._popper=null,this._config=this._getConfig(e),this.tip=null,this._setListeners()}static get Default(){return Ke}static get NAME(){return"tooltip"}static get Event(){return Xe}static get DefaultType(){return $e}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(t){if(this._isEnabled)if(t){const e=this._initializeOnDelegatedTarget(t);e._activeTrigger.click=!e._activeTrigger.click,e._isWithActiveTrigger()?e._enter(null,e):e._leave(null,e)}else{if(this.getTipElement().classList.contains("show"))return void this._leave(null,this);this._enter(null,this)}}dispose(){clearTimeout(this._timeout),P.off(this._element.closest(".modal"),"hide.bs.modal",this._hideModalHandler),this.tip&&this.tip.remove(),this._disposePopper(),super.dispose()}show(){if("none"===this._element.style.display)throw new Error("Please use show on visible elements");if(!this.isWithContent()||!this._isEnabled)return;const t=P.trigger(this._element,this.constructor.Event.SHOW),e=c(this._element),i=null===e?this._element.ownerDocument.documentElement.contains(this._element):e.contains(this._element);if(t.defaultPrevented||!i)return;"tooltip"===this.constructor.NAME&&this.tip&&this.getTitle()!==this.tip.querySelector(".tooltip-inner").innerHTML&&(this._disposePopper(),this.tip.remove(),this.tip=null);const n=this.getTipElement(),s=(t=>{do{t+=Math.floor(1e6*Math.random())}while(document.getElementById(t));return t})(this.constructor.NAME);n.setAttribute("id",s),this._element.setAttribute("aria-describedby",s),this._config.animation&&n.classList.add("fade");const o="function"==typeof this._config.placement?this._config.placement.call(this,n,this._element):this._config.placement,r=this._getAttachment(o);this._addAttachmentClass(r);const{container:a}=this._config;M.set(n,this.constructor.DATA_KEY,this),this._element.ownerDocument.documentElement.contains(this.tip)||(a.append(n),P.trigger(this._element,this.constructor.Event.INSERTED)),this._popper?this._popper.update():this._popper=pe(this._element,n,this._getPopperConfig(r)),n.classList.add("show");const l=this._resolvePossibleFunction(this._config.customClass);l&&n.classList.add(...l.split(" ")),"ontouchstart"in document.documentElement&&[].concat(...document.body.children).forEach(t=>{P.on(t,"mouseover",h)});const d=this.tip.classList.contains("fade");this._queueCallback(()=>{const t=this._hoverState;this._hoverState=null,P.trigger(this._element,this.constructor.Event.SHOWN),"out"===t&&this._leave(null,this)},this.tip,d)}hide(){if(!this._popper)return;const t=this.getTipElement();if(P.trigger(this._element,this.constructor.Event.HIDE).defaultPrevented)return;t.classList.remove("show"),"ontouchstart"in document.documentElement&&[].concat(...document.body.children).forEach(t=>P.off(t,"mouseover",h)),this._activeTrigger.click=!1,this._activeTrigger.focus=!1,this._activeTrigger.hover=!1;const e=this.tip.classList.contains("fade");this._queueCallback(()=>{this._isWithActiveTrigger()||("show"!==this._hoverState&&t.remove(),this._cleanTipClass(),this._element.removeAttribute("aria-describedby"),P.trigger(this._element,this.constructor.Event.HIDDEN),this._disposePopper())},this.tip,e),this._hoverState=""}update(){null!==this._popper&&this._popper.update()}isWithContent(){return Boolean(this.getTitle())}getTipElement(){if(this.tip)return this.tip;const t=document.createElement("div");t.innerHTML=this._config.template;const e=t.children[0];return this.setContent(e),e.classList.remove("fade","show"),this.tip=e,this.tip}setContent(t){this._sanitizeAndSetContent(t,this.getTitle(),".tooltip-inner")}_sanitizeAndSetContent(t,e,i){const n=U.findOne(i,t);e||!n?this.setElementContent(n,e):n.remove()}setElementContent(t,e){if(null!==t)return s(e)?(e=o(e),void(this._config.html?e.parentNode!==t&&(t.innerHTML="",t.append(e)):t.textContent=e.textContent)):void(this._config.html?(this._config.sanitize&&(e=Fe(e,this._config.allowList,this._config.sanitizeFn)),t.innerHTML=e):t.textContent=e)}getTitle(){const t=this._element.getAttribute("data-bs-original-title")||this._config.title;return this._resolvePossibleFunction(t)}updateAttachment(t){return"right"===t?"end":"left"===t?"start":t}_initializeOnDelegatedTarget(t,e){return e||this.constructor.getOrCreateInstance(t.delegateTarget,this._getDelegateConfig())}_getOffset(){const{offset:t}=this._config;return"string"==typeof t?t.split(",").map(t=>Number.parseInt(t,10)):"function"==typeof t?e=>t(e,this._element):t}_resolvePossibleFunction(t){return"function"==typeof t?t.call(this._element):t}_getPopperConfig(t){const e={placement:t,modifiers:[{name:"flip",options:{fallbackPlacements:this._config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"arrow",options:{element:`.${this.constructor.NAME}-arrow`}},{name:"onChange",enabled:!0,phase:"afterWrite",fn:t=>this._handlePopperPlacementChange(t)}],onFirstUpdate:t=>{t.options.placement!==t.placement&&this._handlePopperPlacementChange(t)}};return{...e,..."function"==typeof this._config.popperConfig?this._config.popperConfig(e):this._config.popperConfig}}_addAttachmentClass(t){this.getTipElement().classList.add(`${this._getBasicClassPrefix()}-${this.updateAttachment(t)}`)}_getAttachment(t){return Ve[t.toUpperCase()]}_setListeners(){this._config.trigger.split(" ").forEach(t=>{if("click"===t)P.on(this._element,this.constructor.Event.CLICK,this._config.selector,t=>this.toggle(t));else if("manual"!==t){const e="hover"===t?this.constructor.Event.MOUSEENTER:this.constructor.Event.FOCUSIN,i="hover"===t?this.constructor.Event.MOUSELEAVE:this.constructor.Event.FOCUSOUT;P.on(this._element,e,this._config.selector,t=>this._enter(t)),P.on(this._element,i,this._config.selector,t=>this._leave(t))}}),this._hideModalHandler=()=>{this._element&&this.hide()},P.on(this._element.closest(".modal"),"hide.bs.modal",this._hideModalHandler),this._config.selector?this._config={...this._config,trigger:"manual",selector:""}:this._fixTitle()}_fixTitle(){const t=this._element.getAttribute("title"),e=typeof this._element.getAttribute("data-bs-original-title");(t||"string"!==e)&&(this._element.setAttribute("data-bs-original-title",t||""),!t||this._element.getAttribute("aria-label")||this._element.textContent||this._element.setAttribute("aria-label",t),this._element.setAttribute("title",""))}_enter(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusin"===t.type?"focus":"hover"]=!0),e.getTipElement().classList.contains("show")||"show"===e._hoverState?e._hoverState="show":(clearTimeout(e._timeout),e._hoverState="show",e._config.delay&&e._config.delay.show?e._timeout=setTimeout(()=>{"show"===e._hoverState&&e.show()},e._config.delay.show):e.show())}_leave(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusout"===t.type?"focus":"hover"]=e._element.contains(t.relatedTarget)),e._isWithActiveTrigger()||(clearTimeout(e._timeout),e._hoverState="out",e._config.delay&&e._config.delay.hide?e._timeout=setTimeout(()=>{"out"===e._hoverState&&e.hide()},e._config.delay.hide):e.hide())}_isWithActiveTrigger(){for(const t in this._activeTrigger)if(this._activeTrigger[t])return!0;return!1}_getConfig(t){const e=F.getDataAttributes(this._element);return Object.keys(e).forEach(t=>{Ue.has(t)&&delete e[t]}),(t={...this.constructor.Default,...e,..."object"==typeof t&&t?t:{}}).container=!1===t.container?document.body:o(t.container),"number"==typeof t.delay&&(t.delay={show:t.delay,hide:t.delay}),"number"==typeof t.title&&(t.title=t.title.toString()),"number"==typeof t.content&&(t.content=t.content.toString()),r("tooltip",t,this.constructor.DefaultType),t.sanitize&&(t.template=Fe(t.template,t.allowList,t.sanitizeFn)),t}_getDelegateConfig(){const t={};for(const e in this._config)this.constructor.Default[e]!==this._config[e]&&(t[e]=this._config[e]);return t}_cleanTipClass(){const t=this.getTipElement(),e=new RegExp(`(^|\\s)${this._getBasicClassPrefix()}\\S+`,"g"),i=t.getAttribute("class").match(e);null!==i&&i.length>0&&i.map(t=>t.trim()).forEach(e=>t.classList.remove(e))}_getBasicClassPrefix(){return"bs-tooltip"}_handlePopperPlacementChange(t){const{state:e}=t;e&&(this.tip=e.elements.popper,this._cleanTipClass(),this._addAttachmentClass(this._getAttachment(e.placement)))}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null)}static jQueryInterface(t){return this.each((function(){const e=Ye.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}m(Ye);const Qe={...Ye.Default,placement:"right",offset:[0,8],trigger:"click",content:"",template:''},Ge={...Ye.DefaultType,content:"(string|element|function)"},Ze={HIDE:"hide.bs.popover",HIDDEN:"hidden.bs.popover",SHOW:"show.bs.popover",SHOWN:"shown.bs.popover",INSERTED:"inserted.bs.popover",CLICK:"click.bs.popover",FOCUSIN:"focusin.bs.popover",FOCUSOUT:"focusout.bs.popover",MOUSEENTER:"mouseenter.bs.popover",MOUSELEAVE:"mouseleave.bs.popover"};class Je extends Ye{static get Default(){return Qe}static get NAME(){return"popover"}static get Event(){return Ze}static get DefaultType(){return Ge}isWithContent(){return this.getTitle()||this._getContent()}setContent(t){this._sanitizeAndSetContent(t,this.getTitle(),".popover-header"),this._sanitizeAndSetContent(t,this._getContent(),".popover-body")}_getContent(){return this._resolvePossibleFunction(this._config.content)}_getBasicClassPrefix(){return"bs-popover"}static jQueryInterface(t){return this.each((function(){const e=Je.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}m(Je);const ti={offset:10,method:"auto",target:""},ei={offset:"number",method:"string",target:"(string|element)"},ii=".nav-link, .list-group-item, .dropdown-item";class ni extends H{constructor(t,e){super(t),this._scrollElement="BODY"===this._element.tagName?window:this._element,this._config=this._getConfig(e),this._offsets=[],this._targets=[],this._activeTarget=null,this._scrollHeight=0,P.on(this._scrollElement,"scroll.bs.scrollspy",()=>this._process()),this.refresh(),this._process()}static get Default(){return ti}static get NAME(){return"scrollspy"}refresh(){const t=this._scrollElement===this._scrollElement.window?"offset":"position",i="auto"===this._config.method?t:this._config.method,n="position"===i?this._getScrollTop():0;this._offsets=[],this._targets=[],this._scrollHeight=this._getScrollHeight(),U.find(ii,this._config.target).map(t=>{const s=e(t),o=s?U.findOne(s):null;if(o){const t=o.getBoundingClientRect();if(t.width||t.height)return[F[i](o).top+n,s]}return null}).filter(t=>t).sort((t,e)=>t[0]-e[0]).forEach(t=>{this._offsets.push(t[0]),this._targets.push(t[1])})}dispose(){P.off(this._scrollElement,".bs.scrollspy"),super.dispose()}_getConfig(t){return(t={...ti,...F.getDataAttributes(this._element),..."object"==typeof t&&t?t:{}}).target=o(t.target)||document.documentElement,r("scrollspy",t,ei),t}_getScrollTop(){return this._scrollElement===window?this._scrollElement.pageYOffset:this._scrollElement.scrollTop}_getScrollHeight(){return this._scrollElement.scrollHeight||Math.max(document.body.scrollHeight,document.documentElement.scrollHeight)}_getOffsetHeight(){return this._scrollElement===window?window.innerHeight:this._scrollElement.getBoundingClientRect().height}_process(){const t=this._getScrollTop()+this._config.offset,e=this._getScrollHeight(),i=this._config.offset+e-this._getOffsetHeight();if(this._scrollHeight!==e&&this.refresh(),t>=i){const t=this._targets[this._targets.length-1];this._activeTarget!==t&&this._activate(t)}else{if(this._activeTarget&&t0)return this._activeTarget=null,void this._clear();for(let e=this._offsets.length;e--;)this._activeTarget!==this._targets[e]&&t>=this._offsets[e]&&(void 0===this._offsets[e+1]||t`${e}[data-bs-target="${t}"],${e}[href="${t}"]`),i=U.findOne(e.join(","),this._config.target);i.classList.add("active"),i.classList.contains("dropdown-item")?U.findOne(".dropdown-toggle",i.closest(".dropdown")).classList.add("active"):U.parents(i,".nav, .list-group").forEach(t=>{U.prev(t,".nav-link, .list-group-item").forEach(t=>t.classList.add("active")),U.prev(t,".nav-item").forEach(t=>{U.children(t,".nav-link").forEach(t=>t.classList.add("active"))})}),P.trigger(this._scrollElement,"activate.bs.scrollspy",{relatedTarget:t})}_clear(){U.find(ii,this._config.target).filter(t=>t.classList.contains("active")).forEach(t=>t.classList.remove("active"))}static jQueryInterface(t){return this.each((function(){const e=ni.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}P.on(window,"load.bs.scrollspy.data-api",()=>{U.find('[data-bs-spy="scroll"]').forEach(t=>new ni(t))}),m(ni);class si extends H{static get NAME(){return"tab"}show(){if(this._element.parentNode&&this._element.parentNode.nodeType===Node.ELEMENT_NODE&&this._element.classList.contains("active"))return;let t;const e=i(this._element),n=this._element.closest(".nav, .list-group");if(n){const e="UL"===n.nodeName||"OL"===n.nodeName?":scope > li > .active":".active";t=U.find(e,n),t=t[t.length-1]}const s=t?P.trigger(t,"hide.bs.tab",{relatedTarget:this._element}):null;if(P.trigger(this._element,"show.bs.tab",{relatedTarget:t}).defaultPrevented||null!==s&&s.defaultPrevented)return;this._activate(this._element,n);const o=()=>{P.trigger(t,"hidden.bs.tab",{relatedTarget:this._element}),P.trigger(this._element,"shown.bs.tab",{relatedTarget:t})};e?this._activate(e,e.parentNode,o):o()}_activate(t,e,i){const n=(!e||"UL"!==e.nodeName&&"OL"!==e.nodeName?U.children(e,".active"):U.find(":scope > li > .active",e))[0],s=i&&n&&n.classList.contains("fade"),o=()=>this._transitionComplete(t,n,i);n&&s?(n.classList.remove("show"),this._queueCallback(o,t,!0)):o()}_transitionComplete(t,e,i){if(e){e.classList.remove("active");const t=U.findOne(":scope > .dropdown-menu .active",e.parentNode);t&&t.classList.remove("active"),"tab"===e.getAttribute("role")&&e.setAttribute("aria-selected",!1)}t.classList.add("active"),"tab"===t.getAttribute("role")&&t.setAttribute("aria-selected",!0),d(t),t.classList.contains("fade")&&t.classList.add("show");let n=t.parentNode;if(n&&"LI"===n.nodeName&&(n=n.parentNode),n&&n.classList.contains("dropdown-menu")){const e=t.closest(".dropdown");e&&U.find(".dropdown-toggle",e).forEach(t=>t.classList.add("active")),t.setAttribute("aria-expanded",!0)}i&&i()}static jQueryInterface(t){return this.each((function(){const e=si.getOrCreateInstance(this);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}P.on(document,"click.bs.tab.data-api",'[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',(function(t){["A","AREA"].includes(this.tagName)&&t.preventDefault(),l(this)||si.getOrCreateInstance(this).show()})),m(si);const oi={animation:"boolean",autohide:"boolean",delay:"number"},ri={animation:!0,autohide:!0,delay:5e3};class ai extends H{constructor(t,e){super(t),this._config=this._getConfig(e),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get DefaultType(){return oi}static get Default(){return ri}static get NAME(){return"toast"}show(){P.trigger(this._element,"show.bs.toast").defaultPrevented||(this._clearTimeout(),this._config.animation&&this._element.classList.add("fade"),this._element.classList.remove("hide"),d(this._element),this._element.classList.add("show"),this._element.classList.add("showing"),this._queueCallback(()=>{this._element.classList.remove("showing"),P.trigger(this._element,"shown.bs.toast"),this._maybeScheduleHide()},this._element,this._config.animation))}hide(){this._element.classList.contains("show")&&(P.trigger(this._element,"hide.bs.toast").defaultPrevented||(this._element.classList.add("showing"),this._queueCallback(()=>{this._element.classList.add("hide"),this._element.classList.remove("showing"),this._element.classList.remove("show"),P.trigger(this._element,"hidden.bs.toast")},this._element,this._config.animation)))}dispose(){this._clearTimeout(),this._element.classList.contains("show")&&this._element.classList.remove("show"),super.dispose()}_getConfig(t){return t={...ri,...F.getDataAttributes(this._element),..."object"==typeof t&&t?t:{}},r("toast",t,this.constructor.DefaultType),t}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout(()=>{this.hide()},this._config.delay)))}_onInteraction(t,e){switch(t.type){case"mouseover":case"mouseout":this._hasMouseInteraction=e;break;case"focusin":case"focusout":this._hasKeyboardInteraction=e}if(e)return void this._clearTimeout();const i=t.relatedTarget;this._element===i||this._element.contains(i)||this._maybeScheduleHide()}_setListeners(){P.on(this._element,"mouseover.bs.toast",t=>this._onInteraction(t,!0)),P.on(this._element,"mouseout.bs.toast",t=>this._onInteraction(t,!1)),P.on(this._element,"focusin.bs.toast",t=>this._onInteraction(t,!0)),P.on(this._element,"focusout.bs.toast",t=>this._onInteraction(t,!1))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(t){return this.each((function(){const e=ai.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}return B(ai),m(ai),{Alert:R,Button:W,Carousel:Z,Collapse:et,Dropdown:Oe,Modal:je,Offcanvas:Be,Popover:Je,ScrollSpy:ni,Tab:si,Toast:ai,Tooltip:Ye}})); +//# sourceMappingURL=bootstrap.bundle.min.js.map \ No newline at end of file diff --git a/src/js/vendor/flatpickr.min.js b/src/js/vendor/flatpickr.min.js new file mode 100644 index 0000000..345297f --- /dev/null +++ b/src/js/vendor/flatpickr.min.js @@ -0,0 +1,2 @@ +/* flatpickr v4.6.9,, @license MIT */ +!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).flatpickr=t()}(this,(function(){"use strict";var e=function(){return(e=Object.assign||function(e){for(var t,n=1,a=arguments.length;n",noCalendar:!1,now:new Date,onChange:[],onClose:[],onDayCreate:[],onDestroy:[],onKeyDown:[],onMonthChange:[],onOpen:[],onParseConfig:[],onReady:[],onValueUpdate:[],onYearChange:[],onPreCalendarPosition:[],plugins:[],position:"auto",positionElement:void 0,prevArrow:"",shorthandCurrentMonth:!1,showMonths:1,static:!1,time_24hr:!1,weekNumbers:!1,wrap:!1},i={weekdays:{shorthand:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],longhand:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},months:{shorthand:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],longhand:["January","February","March","April","May","June","July","August","September","October","November","December"]},daysInMonth:[31,28,31,30,31,30,31,31,30,31,30,31],firstDayOfWeek:0,ordinal:function(e){var t=e%100;if(t>3&&t<21)return"th";switch(t%10){case 1:return"st";case 2:return"nd";case 3:return"rd";default:return"th"}},rangeSeparator:" to ",weekAbbreviation:"Wk",scrollTitle:"Scroll to increment",toggleTitle:"Click to toggle",amPM:["AM","PM"],yearAriaLabel:"Year",monthAriaLabel:"Month",hourAriaLabel:"Hour",minuteAriaLabel:"Minute",time_24hr:!1},o=function(e,t){return void 0===t&&(t=2),("000"+e).slice(-1*t)},r=function(e){return!0===e?1:0};function l(e,t){var n;return function(){var a=this;clearTimeout(n),n=setTimeout((function(){return e.apply(a,arguments)}),t)}}var c=function(e){return e instanceof Array?e:[e]};function d(e,t,n){if(!0===n)return e.classList.add(t);e.classList.remove(t)}function s(e,t,n){var a=window.document.createElement(e);return t=t||"",n=n||"",a.className=t,void 0!==n&&(a.textContent=n),a}function u(e){for(;e.firstChild;)e.removeChild(e.firstChild)}function f(e,t){return t(e)?e:e.parentNode?f(e.parentNode,t):void 0}function m(e,t){var n=s("div","numInputWrapper"),a=s("input","numInput "+e),i=s("span","arrowUp"),o=s("span","arrowDown");if(-1===navigator.userAgent.indexOf("MSIE 9.0")?a.type="number":(a.type="text",a.pattern="\\d*"),void 0!==t)for(var r in t)a.setAttribute(r,t[r]);return n.appendChild(a),n.appendChild(i),n.appendChild(o),n}function g(e){try{return"function"==typeof e.composedPath?e.composedPath()[0]:e.target}catch(t){return e.target}}var p=function(){},h=function(e,t,n){return n.months[t?"shorthand":"longhand"][e]},v={D:p,F:function(e,t,n){e.setMonth(n.months.longhand.indexOf(t))},G:function(e,t){e.setHours(parseFloat(t))},H:function(e,t){e.setHours(parseFloat(t))},J:function(e,t){e.setDate(parseFloat(t))},K:function(e,t,n){e.setHours(e.getHours()%12+12*r(new RegExp(n.amPM[1],"i").test(t)))},M:function(e,t,n){e.setMonth(n.months.shorthand.indexOf(t))},S:function(e,t){e.setSeconds(parseFloat(t))},U:function(e,t){return new Date(1e3*parseFloat(t))},W:function(e,t,n){var a=parseInt(t),i=new Date(e.getFullYear(),0,2+7*(a-1),0,0,0,0);return i.setDate(i.getDate()-i.getDay()+n.firstDayOfWeek),i},Y:function(e,t){e.setFullYear(parseFloat(t))},Z:function(e,t){return new Date(t)},d:function(e,t){e.setDate(parseFloat(t))},h:function(e,t){e.setHours(parseFloat(t))},i:function(e,t){e.setMinutes(parseFloat(t))},j:function(e,t){e.setDate(parseFloat(t))},l:p,m:function(e,t){e.setMonth(parseFloat(t)-1)},n:function(e,t){e.setMonth(parseFloat(t)-1)},s:function(e,t){e.setSeconds(parseFloat(t))},u:function(e,t){return new Date(parseFloat(t))},w:p,y:function(e,t){e.setFullYear(2e3+parseFloat(t))}},D={D:"(\\w+)",F:"(\\w+)",G:"(\\d\\d|\\d)",H:"(\\d\\d|\\d)",J:"(\\d\\d|\\d)\\w+",K:"",M:"(\\w+)",S:"(\\d\\d|\\d)",U:"(.+)",W:"(\\d\\d|\\d)",Y:"(\\d{4})",Z:"(.+)",d:"(\\d\\d|\\d)",h:"(\\d\\d|\\d)",i:"(\\d\\d|\\d)",j:"(\\d\\d|\\d)",l:"(\\w+)",m:"(\\d\\d|\\d)",n:"(\\d\\d|\\d)",s:"(\\d\\d|\\d)",u:"(.+)",w:"(\\d\\d|\\d)",y:"(\\d{2})"},w={Z:function(e){return e.toISOString()},D:function(e,t,n){return t.weekdays.shorthand[w.w(e,t,n)]},F:function(e,t,n){return h(w.n(e,t,n)-1,!1,t)},G:function(e,t,n){return o(w.h(e,t,n))},H:function(e){return o(e.getHours())},J:function(e,t){return void 0!==t.ordinal?e.getDate()+t.ordinal(e.getDate()):e.getDate()},K:function(e,t){return t.amPM[r(e.getHours()>11)]},M:function(e,t){return h(e.getMonth(),!0,t)},S:function(e){return o(e.getSeconds())},U:function(e){return e.getTime()/1e3},W:function(e,t,n){return n.getWeek(e)},Y:function(e){return o(e.getFullYear(),4)},d:function(e){return o(e.getDate())},h:function(e){return e.getHours()%12?e.getHours()%12:12},i:function(e){return o(e.getMinutes())},j:function(e){return e.getDate()},l:function(e,t){return t.weekdays.longhand[e.getDay()]},m:function(e){return o(e.getMonth()+1)},n:function(e){return e.getMonth()+1},s:function(e){return e.getSeconds()},u:function(e){return e.getTime()},w:function(e){return e.getDay()},y:function(e){return String(e.getFullYear()).substring(2)}},b=function(e){var t=e.config,n=void 0===t?a:t,o=e.l10n,r=void 0===o?i:o,l=e.isMobile,c=void 0!==l&&l;return function(e,t,a){var i=a||r;return void 0===n.formatDate||c?t.split("").map((function(t,a,o){return w[t]&&"\\"!==o[a-1]?w[t](e,i,n):"\\"!==t?t:""})).join(""):n.formatDate(e,t,i)}},C=function(e){var t=e.config,n=void 0===t?a:t,o=e.l10n,r=void 0===o?i:o;return function(e,t,i,o){if(0===e||e){var l,c=o||r,d=e;if(e instanceof Date)l=new Date(e.getTime());else if("string"!=typeof e&&void 0!==e.toFixed)l=new Date(e);else if("string"==typeof e){var s=t||(n||a).dateFormat,u=String(e).trim();if("today"===u)l=new Date,i=!0;else if(/Z$/.test(u)||/GMT$/.test(u))l=new Date(e);else if(n&&n.parseDate)l=n.parseDate(e,s);else{l=n&&n.noCalendar?new Date((new Date).setHours(0,0,0,0)):new Date((new Date).getFullYear(),0,1,0,0,0,0);for(var f=void 0,m=[],g=0,p=0,h="";g=0?new Date:new Date(w.config.minDate.getTime()),n=x(w.config);t.setHours(n.hours,n.minutes,n.seconds,t.getMilliseconds()),w.selectedDates=[t],w.latestSelectedDateObj=t}void 0!==e&&"blur"!==e.type&&function(e){e.preventDefault();var t="keydown"===e.type,n=g(e),a=n;void 0!==w.amPM&&n===w.amPM&&(w.amPM.textContent=w.l10n.amPM[r(w.amPM.textContent===w.l10n.amPM[0])]);var i=parseFloat(a.getAttribute("min")),l=parseFloat(a.getAttribute("max")),c=parseFloat(a.getAttribute("step")),d=parseInt(a.value,10),s=e.delta||(t?38===e.which?1:-1:0),u=d+c*s;if(void 0!==a.value&&2===a.value.length){var f=a===w.hourElement,m=a===w.minuteElement;ul&&(u=a===w.hourElement?u-l-r(!w.amPM):i,m&&j(void 0,1,w.hourElement)),w.amPM&&f&&(1===c?u+d===23:Math.abs(u-d)>c)&&(w.amPM.textContent=w.l10n.amPM[r(w.amPM.textContent===w.l10n.amPM[0])]),a.value=o(u)}}(e);var a=w._input.value;S(),be(),w._input.value!==a&&w._debouncedChange()}function S(){if(void 0!==w.hourElement&&void 0!==w.minuteElement){var e,t,n=(parseInt(w.hourElement.value.slice(-2),10)||0)%24,a=(parseInt(w.minuteElement.value,10)||0)%60,i=void 0!==w.secondElement?(parseInt(w.secondElement.value,10)||0)%60:0;void 0!==w.amPM&&(e=n,t=w.amPM.textContent,n=e%12+12*r(t===w.l10n.amPM[1]));var o=void 0!==w.config.minTime||w.config.minDate&&w.minDateHasTime&&w.latestSelectedDateObj&&0===M(w.latestSelectedDateObj,w.config.minDate,!0);if(void 0!==w.config.maxTime||w.config.maxDate&&w.maxDateHasTime&&w.latestSelectedDateObj&&0===M(w.latestSelectedDateObj,w.config.maxDate,!0)){var l=void 0!==w.config.maxTime?w.config.maxTime:w.config.maxDate;(n=Math.min(n,l.getHours()))===l.getHours()&&(a=Math.min(a,l.getMinutes())),a===l.getMinutes()&&(i=Math.min(i,l.getSeconds()))}if(o){var c=void 0!==w.config.minTime?w.config.minTime:w.config.minDate;(n=Math.max(n,c.getHours()))===c.getHours()&&a=12)]),void 0!==w.secondElement&&(w.secondElement.value=o(n)))}function F(e){var t=g(e),n=parseInt(t.value)+(e.delta||0);(n/1e3>1||"Enter"===e.key&&!/[^\d]/.test(n.toString()))&&Q(n)}function A(e,t,n,a){return t instanceof Array?t.forEach((function(t){return A(e,t,n,a)})):e instanceof Array?e.forEach((function(e){return A(e,t,n,a)})):(e.addEventListener(t,n,a),void w._handlers.push({remove:function(){return e.removeEventListener(t,n)}}))}function N(){pe("onChange")}function P(e,t){var n=void 0!==e?w.parseDate(e):w.latestSelectedDateObj||(w.config.minDate&&w.config.minDate>w.now?w.config.minDate:w.config.maxDate&&w.config.maxDate=0&&M(e,w.selectedDates[1])<=0)}(t)&&!ve(t)&&o.classList.add("inRange"),w.weekNumbers&&1===w.config.showMonths&&"prevMonthDay"!==e&&n%7==1&&w.weekNumbers.insertAdjacentHTML("beforeend",""+w.config.getWeek(t)+""),pe("onDayCreate",o),o}function L(e){e.focus(),"range"===w.config.mode&&ae(e)}function W(e){for(var t=e>0?0:w.config.showMonths-1,n=e>0?w.config.showMonths:-1,a=t;a!=n;a+=e)for(var i=w.daysContainer.children[a],o=e>0?0:i.children.length-1,r=e>0?i.children.length:-1,l=o;l!=r;l+=e){var c=i.children[l];if(-1===c.className.indexOf("hidden")&&X(c.dateObj))return c}}function R(e,t){var n=ee(document.activeElement||document.body),a=void 0!==e?e:n?document.activeElement:void 0!==w.selectedDateElem&&ee(w.selectedDateElem)?w.selectedDateElem:void 0!==w.todayDateElem&&ee(w.todayDateElem)?w.todayDateElem:W(t>0?1:-1);void 0===a?w._input.focus():n?function(e,t){for(var n=-1===e.className.indexOf("Month")?e.dateObj.getMonth():w.currentMonth,a=t>0?w.config.showMonths:-1,i=t>0?1:-1,o=n-w.currentMonth;o!=a;o+=i)for(var r=w.daysContainer.children[o],l=n-w.currentMonth===o?e.$i+t:t<0?r.children.length-1:0,c=r.children.length,d=l;d>=0&&d0?c:-1);d+=i){var s=r.children[d];if(-1===s.className.indexOf("hidden")&&X(s.dateObj)&&Math.abs(e.$i-d)>=Math.abs(t))return L(s)}w.changeMonth(i),R(W(i),0)}(a,t):L(a)}function B(e,t){for(var n=(new Date(e,t,1).getDay()-w.l10n.firstDayOfWeek+7)%7,a=w.utils.getDaysInMonth((t-1+12)%12,e),i=w.utils.getDaysInMonth(t,e),o=window.document.createDocumentFragment(),r=w.config.showMonths>1,l=r?"prevMonthDay hidden":"prevMonthDay",c=r?"nextMonthDay hidden":"nextMonthDay",d=a+1-n,u=0;d<=a;d++,u++)o.appendChild(H(l,new Date(e,t-1,d),d,u));for(d=1;d<=i;d++,u++)o.appendChild(H("",new Date(e,t,d),d,u));for(var f=i+1;f<=42-n&&(1===w.config.showMonths||u%7!=0);f++,u++)o.appendChild(H(c,new Date(e,t+1,f%i),f,u));var m=s("div","dayContainer");return m.appendChild(o),m}function J(){if(void 0!==w.daysContainer){u(w.daysContainer),w.weekNumbers&&u(w.weekNumbers);for(var e=document.createDocumentFragment(),t=0;t1||"dropdown"!==w.config.monthSelectorType)){var e=function(e){return!(void 0!==w.config.minDate&&w.currentYear===w.config.minDate.getFullYear()&&ew.config.maxDate.getMonth())};w.monthsDropdownContainer.tabIndex=-1,w.monthsDropdownContainer.innerHTML="";for(var t=0;t<12;t++)if(e(t)){var n=s("option","flatpickr-monthDropdown-month");n.value=new Date(w.currentYear,t).getMonth().toString(),n.textContent=h(t,w.config.shorthandCurrentMonth,w.l10n),n.tabIndex=-1,w.currentMonth===t&&(n.selected=!0),w.monthsDropdownContainer.appendChild(n)}}}function U(){var e,t=s("div","flatpickr-month"),n=window.document.createDocumentFragment();w.config.showMonths>1||"static"===w.config.monthSelectorType?e=s("span","cur-month"):(w.monthsDropdownContainer=s("select","flatpickr-monthDropdown-months"),w.monthsDropdownContainer.setAttribute("aria-label",w.l10n.monthAriaLabel),A(w.monthsDropdownContainer,"change",(function(e){var t=g(e),n=parseInt(t.value,10);w.changeMonth(n-w.currentMonth),pe("onMonthChange")})),K(),e=w.monthsDropdownContainer);var a=m("cur-year",{tabindex:"-1"}),i=a.getElementsByTagName("input")[0];i.setAttribute("aria-label",w.l10n.yearAriaLabel),w.config.minDate&&i.setAttribute("min",w.config.minDate.getFullYear().toString()),w.config.maxDate&&(i.setAttribute("max",w.config.maxDate.getFullYear().toString()),i.disabled=!!w.config.minDate&&w.config.minDate.getFullYear()===w.config.maxDate.getFullYear());var o=s("div","flatpickr-current-month");return o.appendChild(e),o.appendChild(a),n.appendChild(o),t.appendChild(n),{container:t,yearElement:i,monthElement:e}}function q(){u(w.monthNav),w.monthNav.appendChild(w.prevMonthNav),w.config.showMonths&&(w.yearElements=[],w.monthElements=[]);for(var e=w.config.showMonths;e--;){var t=U();w.yearElements.push(t.yearElement),w.monthElements.push(t.monthElement),w.monthNav.appendChild(t.container)}w.monthNav.appendChild(w.nextMonthNav)}function $(){w.weekdayContainer?u(w.weekdayContainer):w.weekdayContainer=s("div","flatpickr-weekdays");for(var e=w.config.showMonths;e--;){var t=s("div","flatpickr-weekdaycontainer");w.weekdayContainer.appendChild(t)}return z(),w.weekdayContainer}function z(){if(w.weekdayContainer){var e=w.l10n.firstDayOfWeek,n=t(w.l10n.weekdays.shorthand);e>0&&e\n "+n.join("")+"\n \n "}}function G(e,t){void 0===t&&(t=!0);var n=t?e:e-w.currentMonth;n<0&&!0===w._hidePrevMonthArrow||n>0&&!0===w._hideNextMonthArrow||(w.currentMonth+=n,(w.currentMonth<0||w.currentMonth>11)&&(w.currentYear+=w.currentMonth>11?1:-1,w.currentMonth=(w.currentMonth+12)%12,pe("onYearChange"),K()),J(),pe("onMonthChange"),De())}function V(e){return!(!w.config.appendTo||!w.config.appendTo.contains(e))||w.calendarContainer.contains(e)}function Z(e){if(w.isOpen&&!w.config.inline){var t=g(e),n=V(t),a=t===w.input||t===w.altInput||w.element.contains(t)||e.path&&e.path.indexOf&&(~e.path.indexOf(w.input)||~e.path.indexOf(w.altInput)),i="blur"===e.type?a&&e.relatedTarget&&!V(e.relatedTarget):!a&&!n&&!V(e.relatedTarget),o=!w.config.ignoredFocusElements.some((function(e){return e.contains(t)}));i&&o&&(void 0!==w.timeContainer&&void 0!==w.minuteElement&&void 0!==w.hourElement&&""!==w.input.value&&void 0!==w.input.value&&I(),w.close(),w.config&&"range"===w.config.mode&&1===w.selectedDates.length&&(w.clear(!1),w.redraw()))}}function Q(e){if(!(!e||w.config.minDate&&ew.config.maxDate.getFullYear())){var t=e,n=w.currentYear!==t;w.currentYear=t||w.currentYear,w.config.maxDate&&w.currentYear===w.config.maxDate.getFullYear()?w.currentMonth=Math.min(w.config.maxDate.getMonth(),w.currentMonth):w.config.minDate&&w.currentYear===w.config.minDate.getFullYear()&&(w.currentMonth=Math.max(w.config.minDate.getMonth(),w.currentMonth)),n&&(w.redraw(),pe("onYearChange"),K())}}function X(e,t){var n;void 0===t&&(t=!0);var a=w.parseDate(e,void 0,t);if(w.config.minDate&&a&&M(a,w.config.minDate,void 0!==t?t:!w.minDateHasTime)<0||w.config.maxDate&&a&&M(a,w.config.maxDate,void 0!==t?t:!w.maxDateHasTime)>0)return!1;if(!w.config.enable&&0===w.config.disable.length)return!0;if(void 0===a)return!1;for(var i=!!w.config.enable,o=null!==(n=w.config.enable)&&void 0!==n?n:w.config.disable,r=0,l=void 0;r=l.from.getTime()&&a.getTime()<=l.to.getTime())return i}return!i}function ee(e){return void 0!==w.daysContainer&&(-1===e.className.indexOf("hidden")&&-1===e.className.indexOf("flatpickr-disabled")&&w.daysContainer.contains(e))}function te(e){!(e.target===w._input)||!(w.selectedDates.length>0||w._input.value.length>0)||e.relatedTarget&&V(e.relatedTarget)||w.setDate(w._input.value,!0,e.target===w.altInput?w.config.altFormat:w.config.dateFormat)}function ne(e){var t=g(e),n=w.config.wrap?p.contains(t):t===w._input,a=w.config.allowInput,i=w.isOpen&&(!a||!n),o=w.config.inline&&n&&!a;if(13===e.keyCode&&n){if(a)return w.setDate(w._input.value,!0,t===w.altInput?w.config.altFormat:w.config.dateFormat),t.blur();w.open()}else if(V(t)||i||o){var r=!!w.timeContainer&&w.timeContainer.contains(t);switch(e.keyCode){case 13:r?(e.preventDefault(),I(),se()):ue(e);break;case 27:e.preventDefault(),se();break;case 8:case 46:n&&!w.config.allowInput&&(e.preventDefault(),w.clear());break;case 37:case 39:if(r||n)w.hourElement&&w.hourElement.focus();else if(e.preventDefault(),void 0!==w.daysContainer&&(!1===a||document.activeElement&&ee(document.activeElement))){var l=39===e.keyCode?1:-1;e.ctrlKey?(e.stopPropagation(),G(l),R(W(1),0)):R(void 0,l)}break;case 38:case 40:e.preventDefault();var c=40===e.keyCode?1:-1;w.daysContainer&&void 0!==t.$i||t===w.input||t===w.altInput?e.ctrlKey?(e.stopPropagation(),Q(w.currentYear-c),R(W(1),0)):r||R(void 0,7*c):t===w.currentYearElement?Q(w.currentYear-c):w.config.enableTime&&(!r&&w.hourElement&&w.hourElement.focus(),I(e),w._debouncedChange());break;case 9:if(r){var d=[w.hourElement,w.minuteElement,w.secondElement,w.amPM].concat(w.pluginElements).filter((function(e){return e})),s=d.indexOf(t);if(-1!==s){var u=d[s+(e.shiftKey?-1:1)];e.preventDefault(),(u||w._input).focus()}}else!w.config.noCalendar&&w.daysContainer&&w.daysContainer.contains(t)&&e.shiftKey&&(e.preventDefault(),w._input.focus())}}if(void 0!==w.amPM&&t===w.amPM)switch(e.key){case w.l10n.amPM[0].charAt(0):case w.l10n.amPM[0].charAt(0).toLowerCase():w.amPM.textContent=w.l10n.amPM[0],S(),be();break;case w.l10n.amPM[1].charAt(0):case w.l10n.amPM[1].charAt(0).toLowerCase():w.amPM.textContent=w.l10n.amPM[1],S(),be()}(n||V(t))&&pe("onKeyDown",e)}function ae(e){if(1===w.selectedDates.length&&(!e||e.classList.contains("flatpickr-day")&&!e.classList.contains("flatpickr-disabled"))){for(var t=e?e.dateObj.getTime():w.days.firstElementChild.dateObj.getTime(),n=w.parseDate(w.selectedDates[0],void 0,!0).getTime(),a=Math.min(t,w.selectedDates[0].getTime()),i=Math.max(t,w.selectedDates[0].getTime()),o=!1,r=0,l=0,c=a;ca&&cr)?r=c:c>n&&(!l||c0&&m0&&m>l;return g?(f.classList.add("notAllowed"),["inRange","startRange","endRange"].forEach((function(e){f.classList.remove(e)})),"continue"):o&&!g?"continue":(["startRange","inRange","endRange","notAllowed"].forEach((function(e){f.classList.remove(e)})),void(void 0!==e&&(e.classList.add(t<=w.selectedDates[0].getTime()?"startRange":"endRange"),nt&&m===n&&f.classList.add("endRange"),m>=r&&(0===l||m<=l)&&(d=n,u=t,(c=m)>Math.min(d,u)&&c0||n.getMinutes()>0||n.getSeconds()>0),w.selectedDates&&(w.selectedDates=w.selectedDates.filter((function(e){return X(e)})),w.selectedDates.length||"min"!==e||_(n),be()),w.daysContainer&&(de(),void 0!==n?w.currentYearElement[e]=n.getFullYear().toString():w.currentYearElement.removeAttribute(e),w.currentYearElement.disabled=!!a&&void 0!==n&&a.getFullYear()===n.getFullYear())}}function re(){return w.config.wrap?p.querySelector("[data-input]"):p}function le(){"object"!=typeof w.config.locale&&void 0===T.l10ns[w.config.locale]&&w.config.errorHandler(new Error("flatpickr: invalid locale "+w.config.locale)),w.l10n=e(e({},T.l10ns.default),"object"==typeof w.config.locale?w.config.locale:"default"!==w.config.locale?T.l10ns[w.config.locale]:void 0),D.K="("+w.l10n.amPM[0]+"|"+w.l10n.amPM[1]+"|"+w.l10n.amPM[0].toLowerCase()+"|"+w.l10n.amPM[1].toLowerCase()+")",void 0===e(e({},v),JSON.parse(JSON.stringify(p.dataset||{}))).time_24hr&&void 0===T.defaultConfig.time_24hr&&(w.config.time_24hr=w.l10n.time_24hr),w.formatDate=b(w),w.parseDate=C({config:w.config,l10n:w.l10n})}function ce(e){if("function"!=typeof w.config.position){if(void 0!==w.calendarContainer){pe("onPreCalendarPosition");var t=e||w._positionElement,n=Array.prototype.reduce.call(w.calendarContainer.children,(function(e,t){return e+t.offsetHeight}),0),a=w.calendarContainer.offsetWidth,i=w.config.position.split(" "),o=i[0],r=i.length>1?i[1]:null,l=t.getBoundingClientRect(),c=window.innerHeight-l.bottom,s="above"===o||"below"!==o&&cn,u=window.pageYOffset+l.top+(s?-n-2:t.offsetHeight+2);if(d(w.calendarContainer,"arrowTop",!s),d(w.calendarContainer,"arrowBottom",s),!w.config.inline){var f=window.pageXOffset+l.left,m=!1,g=!1;"center"===r?(f-=(a-l.width)/2,m=!0):"right"===r&&(f-=a-l.width,g=!0),d(w.calendarContainer,"arrowLeft",!m&&!g),d(w.calendarContainer,"arrowCenter",m),d(w.calendarContainer,"arrowRight",g);var p=window.document.body.offsetWidth-(window.pageXOffset+l.right),h=f+a>window.document.body.offsetWidth,v=p+a>window.document.body.offsetWidth;if(d(w.calendarContainer,"rightMost",h),!w.config.static)if(w.calendarContainer.style.top=u+"px",h)if(v){var D=function(){for(var e=null,t=0;tw.currentMonth+w.config.showMonths-1)&&"range"!==w.config.mode;if(w.selectedDateElem=n,"single"===w.config.mode)w.selectedDates=[a];else if("multiple"===w.config.mode){var o=ve(a);o?w.selectedDates.splice(parseInt(o),1):w.selectedDates.push(a)}else"range"===w.config.mode&&(2===w.selectedDates.length&&w.clear(!1,!1),w.latestSelectedDateObj=a,w.selectedDates.push(a),0!==M(a,w.selectedDates[0],!0)&&w.selectedDates.sort((function(e,t){return e.getTime()-t.getTime()})));if(S(),i){var r=w.currentYear!==a.getFullYear();w.currentYear=a.getFullYear(),w.currentMonth=a.getMonth(),r&&(pe("onYearChange"),K()),pe("onMonthChange")}if(De(),J(),be(),i||"range"===w.config.mode||1!==w.config.showMonths?void 0!==w.selectedDateElem&&void 0===w.hourElement&&w.selectedDateElem&&w.selectedDateElem.focus():L(n),void 0!==w.hourElement&&void 0!==w.hourElement&&w.hourElement.focus(),w.config.closeOnSelect){var l="single"===w.config.mode&&!w.config.enableTime,c="range"===w.config.mode&&2===w.selectedDates.length&&!w.config.enableTime;(l||c)&&se()}N()}}w.parseDate=C({config:w.config,l10n:w.l10n}),w._handlers=[],w.pluginElements=[],w.loadedPlugins=[],w._bind=A,w._setHoursFromDate=_,w._positionCalendar=ce,w.changeMonth=G,w.changeYear=Q,w.clear=function(e,t){void 0===e&&(e=!0);void 0===t&&(t=!0);w.input.value="",void 0!==w.altInput&&(w.altInput.value="");void 0!==w.mobileInput&&(w.mobileInput.value="");w.selectedDates=[],w.latestSelectedDateObj=void 0,!0===t&&(w.currentYear=w._initialDate.getFullYear(),w.currentMonth=w._initialDate.getMonth());if(!0===w.config.enableTime){var n=x(w.config),a=n.hours,i=n.minutes,o=n.seconds;O(a,i,o)}w.redraw(),e&&pe("onChange")},w.close=function(){w.isOpen=!1,w.isMobile||(void 0!==w.calendarContainer&&w.calendarContainer.classList.remove("open"),void 0!==w._input&&w._input.classList.remove("active"));pe("onClose")},w._createElement=s,w.destroy=function(){void 0!==w.config&&pe("onDestroy");for(var e=w._handlers.length;e--;)w._handlers[e].remove();if(w._handlers=[],w.mobileInput)w.mobileInput.parentNode&&w.mobileInput.parentNode.removeChild(w.mobileInput),w.mobileInput=void 0;else if(w.calendarContainer&&w.calendarContainer.parentNode)if(w.config.static&&w.calendarContainer.parentNode){var t=w.calendarContainer.parentNode;if(t.lastChild&&t.removeChild(t.lastChild),t.parentNode){for(;t.firstChild;)t.parentNode.insertBefore(t.firstChild,t);t.parentNode.removeChild(t)}}else w.calendarContainer.parentNode.removeChild(w.calendarContainer);w.altInput&&(w.input.type="text",w.altInput.parentNode&&w.altInput.parentNode.removeChild(w.altInput),delete w.altInput);w.input&&(w.input.type=w.input._type,w.input.classList.remove("flatpickr-input"),w.input.removeAttribute("readonly"));["_showTimeInput","latestSelectedDateObj","_hideNextMonthArrow","_hidePrevMonthArrow","__hideNextMonthArrow","__hidePrevMonthArrow","isMobile","isOpen","selectedDateElem","minDateHasTime","maxDateHasTime","days","daysContainer","_input","_positionElement","innerContainer","rContainer","monthNav","todayDateElem","calendarContainer","weekdayContainer","prevMonthNav","nextMonthNav","monthsDropdownContainer","currentMonthElement","currentYearElement","navigationCurrentMonth","selectedDateElem","config"].forEach((function(e){try{delete w[e]}catch(e){}}))},w.isEnabled=X,w.jumpToDate=P,w.open=function(e,t){void 0===t&&(t=w._positionElement);if(!0===w.isMobile){if(e){e.preventDefault();var n=g(e);n&&n.blur()}return void 0!==w.mobileInput&&(w.mobileInput.focus(),w.mobileInput.click()),void pe("onOpen")}if(w._input.disabled||w.config.inline)return;var a=w.isOpen;w.isOpen=!0,a||(w.calendarContainer.classList.add("open"),w._input.classList.add("active"),pe("onOpen"),ce(t));!0===w.config.enableTime&&!0===w.config.noCalendar&&(!1!==w.config.allowInput||void 0!==e&&w.timeContainer.contains(e.relatedTarget)||setTimeout((function(){return w.hourElement.select()}),50))},w.redraw=de,w.set=function(e,t){if(null!==e&&"object"==typeof e)for(var a in Object.assign(w.config,e),e)void 0!==fe[a]&&fe[a].forEach((function(e){return e()}));else w.config[e]=t,void 0!==fe[e]?fe[e].forEach((function(e){return e()})):n.indexOf(e)>-1&&(w.config[e]=c(t));w.redraw(),be(!0)},w.setDate=function(e,t,n){void 0===t&&(t=!1);void 0===n&&(n=w.config.dateFormat);if(0!==e&&!e||e instanceof Array&&0===e.length)return w.clear(t);me(e,n),w.latestSelectedDateObj=w.selectedDates[w.selectedDates.length-1],w.redraw(),P(void 0,t),_(),0===w.selectedDates.length&&w.clear(!1);be(t),t&&pe("onChange")},w.toggle=function(e){if(!0===w.isOpen)return w.close();w.open(e)};var fe={locale:[le,z],showMonths:[q,k,$],minDate:[P],maxDate:[P],clickOpens:[function(){!0===w.config.clickOpens?(A(w._input,"focus",w.open),A(w._input,"click",w.open)):(w._input.removeEventListener("focus",w.open),w._input.removeEventListener("click",w.open))}]};function me(e,t){var n=[];if(e instanceof Array)n=e.map((function(e){return w.parseDate(e,t)}));else if(e instanceof Date||"number"==typeof e)n=[w.parseDate(e,t)];else if("string"==typeof e)switch(w.config.mode){case"single":case"time":n=[w.parseDate(e,t)];break;case"multiple":n=e.split(w.config.conjunction).map((function(e){return w.parseDate(e,t)}));break;case"range":n=e.split(w.l10n.rangeSeparator).map((function(e){return w.parseDate(e,t)}))}else w.config.errorHandler(new Error("Invalid date supplied: "+JSON.stringify(e)));w.selectedDates=w.config.allowInvalidPreload?n:n.filter((function(e){return e instanceof Date&&X(e,!1)})),"range"===w.config.mode&&w.selectedDates.sort((function(e,t){return e.getTime()-t.getTime()}))}function ge(e){return e.slice().map((function(e){return"string"==typeof e||"number"==typeof e||e instanceof Date?w.parseDate(e,void 0,!0):e&&"object"==typeof e&&e.from&&e.to?{from:w.parseDate(e.from,void 0),to:w.parseDate(e.to,void 0)}:e})).filter((function(e){return e}))}function pe(e,t){if(void 0!==w.config){var n=w.config[e];if(void 0!==n&&n.length>0)for(var a=0;n[a]&&a1||"static"===w.config.monthSelectorType?w.monthElements[t].textContent=h(n.getMonth(),w.config.shorthandCurrentMonth,w.l10n)+" ":w.monthsDropdownContainer.value=n.getMonth().toString(),e.value=n.getFullYear().toString()})),w._hidePrevMonthArrow=void 0!==w.config.minDate&&(w.currentYear===w.config.minDate.getFullYear()?w.currentMonth<=w.config.minDate.getMonth():w.currentYearw.config.maxDate.getMonth():w.currentYear>w.config.maxDate.getFullYear()))}function we(e){return w.selectedDates.map((function(t){return w.formatDate(t,e)})).filter((function(e,t,n){return"range"!==w.config.mode||w.config.enableTime||n.indexOf(e)===t})).join("range"!==w.config.mode?w.config.conjunction:w.l10n.rangeSeparator)}function be(e){void 0===e&&(e=!0),void 0!==w.mobileInput&&w.mobileFormatStr&&(w.mobileInput.value=void 0!==w.latestSelectedDateObj?w.formatDate(w.latestSelectedDateObj,w.mobileFormatStr):""),w.input.value=we(w.config.dateFormat),void 0!==w.altInput&&(w.altInput.value=we(w.config.altFormat)),!1!==e&&pe("onValueUpdate")}function Ce(e){var t=g(e),n=w.prevMonthNav.contains(t),a=w.nextMonthNav.contains(t);n||a?G(n?-1:1):w.yearElements.indexOf(t)>=0?t.select():t.classList.contains("arrowUp")?w.changeYear(w.currentYear+1):t.classList.contains("arrowDown")&&w.changeYear(w.currentYear-1)}return function(){w.element=w.input=p,w.isOpen=!1,function(){var t=["wrap","weekNumbers","allowInput","allowInvalidPreload","clickOpens","time_24hr","enableTime","noCalendar","altInput","shorthandCurrentMonth","inline","static","enableSeconds","disableMobile"],i=e(e({},JSON.parse(JSON.stringify(p.dataset||{}))),v),o={};w.config.parseDate=i.parseDate,w.config.formatDate=i.formatDate,Object.defineProperty(w.config,"enable",{get:function(){return w.config._enable},set:function(e){w.config._enable=ge(e)}}),Object.defineProperty(w.config,"disable",{get:function(){return w.config._disable},set:function(e){w.config._disable=ge(e)}});var r="time"===i.mode;if(!i.dateFormat&&(i.enableTime||r)){var l=T.defaultConfig.dateFormat||a.dateFormat;o.dateFormat=i.noCalendar||r?"H:i"+(i.enableSeconds?":S":""):l+" H:i"+(i.enableSeconds?":S":"")}if(i.altInput&&(i.enableTime||r)&&!i.altFormat){var d=T.defaultConfig.altFormat||a.altFormat;o.altFormat=i.noCalendar||r?"h:i"+(i.enableSeconds?":S K":" K"):d+" h:i"+(i.enableSeconds?":S":"")+" K"}Object.defineProperty(w.config,"minDate",{get:function(){return w.config._minDate},set:oe("min")}),Object.defineProperty(w.config,"maxDate",{get:function(){return w.config._maxDate},set:oe("max")});var s=function(e){return function(t){w.config["min"===e?"_minTime":"_maxTime"]=w.parseDate(t,"H:i:S")}};Object.defineProperty(w.config,"minTime",{get:function(){return w.config._minTime},set:s("min")}),Object.defineProperty(w.config,"maxTime",{get:function(){return w.config._maxTime},set:s("max")}),"time"===i.mode&&(w.config.noCalendar=!0,w.config.enableTime=!0);Object.assign(w.config,o,i);for(var u=0;u-1?w.config[m]=c(f[m]).map(E).concat(w.config[m]):void 0===i[m]&&(w.config[m]=f[m])}i.altInputClass||(w.config.altInputClass=re().className+" "+w.config.altInputClass);pe("onParseConfig")}(),le(),function(){if(w.input=re(),!w.input)return void w.config.errorHandler(new Error("Invalid input element specified"));w.input._type=w.input.type,w.input.type="text",w.input.classList.add("flatpickr-input"),w._input=w.input,w.config.altInput&&(w.altInput=s(w.input.nodeName,w.config.altInputClass),w._input=w.altInput,w.altInput.placeholder=w.input.placeholder,w.altInput.disabled=w.input.disabled,w.altInput.required=w.input.required,w.altInput.tabIndex=w.input.tabIndex,w.altInput.type="text",w.input.setAttribute("type","hidden"),!w.config.static&&w.input.parentNode&&w.input.parentNode.insertBefore(w.altInput,w.input.nextSibling));w.config.allowInput||w._input.setAttribute("readonly","readonly");w._positionElement=w.config.positionElement||w._input}(),function(){w.selectedDates=[],w.now=w.parseDate(w.config.now)||new Date;var e=w.config.defaultDate||("INPUT"!==w.input.nodeName&&"TEXTAREA"!==w.input.nodeName||!w.input.placeholder||w.input.value!==w.input.placeholder?w.input.value:null);e&&me(e,w.config.dateFormat);w._initialDate=w.selectedDates.length>0?w.selectedDates[0]:w.config.minDate&&w.config.minDate.getTime()>w.now.getTime()?w.config.minDate:w.config.maxDate&&w.config.maxDate.getTime()0&&(w.latestSelectedDateObj=w.selectedDates[0]);void 0!==w.config.minTime&&(w.config.minTime=w.parseDate(w.config.minTime,"H:i"));void 0!==w.config.maxTime&&(w.config.maxTime=w.parseDate(w.config.maxTime,"H:i"));w.minDateHasTime=!!w.config.minDate&&(w.config.minDate.getHours()>0||w.config.minDate.getMinutes()>0||w.config.minDate.getSeconds()>0),w.maxDateHasTime=!!w.config.maxDate&&(w.config.maxDate.getHours()>0||w.config.maxDate.getMinutes()>0||w.config.maxDate.getSeconds()>0)}(),w.utils={getDaysInMonth:function(e,t){return void 0===e&&(e=w.currentMonth),void 0===t&&(t=w.currentYear),1===e&&(t%4==0&&t%100!=0||t%400==0)?29:w.l10n.daysInMonth[e]}},w.isMobile||function(){var e=window.document.createDocumentFragment();if(w.calendarContainer=s("div","flatpickr-calendar"),w.calendarContainer.tabIndex=-1,!w.config.noCalendar){if(e.appendChild((w.monthNav=s("div","flatpickr-months"),w.yearElements=[],w.monthElements=[],w.prevMonthNav=s("span","flatpickr-prev-month"),w.prevMonthNav.innerHTML=w.config.prevArrow,w.nextMonthNav=s("span","flatpickr-next-month"),w.nextMonthNav.innerHTML=w.config.nextArrow,q(),Object.defineProperty(w,"_hidePrevMonthArrow",{get:function(){return w.__hidePrevMonthArrow},set:function(e){w.__hidePrevMonthArrow!==e&&(d(w.prevMonthNav,"flatpickr-disabled",e),w.__hidePrevMonthArrow=e)}}),Object.defineProperty(w,"_hideNextMonthArrow",{get:function(){return w.__hideNextMonthArrow},set:function(e){w.__hideNextMonthArrow!==e&&(d(w.nextMonthNav,"flatpickr-disabled",e),w.__hideNextMonthArrow=e)}}),w.currentYearElement=w.yearElements[0],De(),w.monthNav)),w.innerContainer=s("div","flatpickr-innerContainer"),w.config.weekNumbers){var t=function(){w.calendarContainer.classList.add("hasWeeks");var e=s("div","flatpickr-weekwrapper");e.appendChild(s("span","flatpickr-weekday",w.l10n.weekAbbreviation));var t=s("div","flatpickr-weeks");return e.appendChild(t),{weekWrapper:e,weekNumbers:t}}(),n=t.weekWrapper,a=t.weekNumbers;w.innerContainer.appendChild(n),w.weekNumbers=a,w.weekWrapper=n}w.rContainer=s("div","flatpickr-rContainer"),w.rContainer.appendChild($()),w.daysContainer||(w.daysContainer=s("div","flatpickr-days"),w.daysContainer.tabIndex=-1),J(),w.rContainer.appendChild(w.daysContainer),w.innerContainer.appendChild(w.rContainer),e.appendChild(w.innerContainer)}w.config.enableTime&&e.appendChild(function(){w.calendarContainer.classList.add("hasTime"),w.config.noCalendar&&w.calendarContainer.classList.add("noCalendar");var e=x(w.config);w.timeContainer=s("div","flatpickr-time"),w.timeContainer.tabIndex=-1;var t=s("span","flatpickr-time-separator",":"),n=m("flatpickr-hour",{"aria-label":w.l10n.hourAriaLabel});w.hourElement=n.getElementsByTagName("input")[0];var a=m("flatpickr-minute",{"aria-label":w.l10n.minuteAriaLabel});w.minuteElement=a.getElementsByTagName("input")[0],w.hourElement.tabIndex=w.minuteElement.tabIndex=-1,w.hourElement.value=o(w.latestSelectedDateObj?w.latestSelectedDateObj.getHours():w.config.time_24hr?e.hours:function(e){switch(e%24){case 0:case 12:return 12;default:return e%12}}(e.hours)),w.minuteElement.value=o(w.latestSelectedDateObj?w.latestSelectedDateObj.getMinutes():e.minutes),w.hourElement.setAttribute("step",w.config.hourIncrement.toString()),w.minuteElement.setAttribute("step",w.config.minuteIncrement.toString()),w.hourElement.setAttribute("min",w.config.time_24hr?"0":"1"),w.hourElement.setAttribute("max",w.config.time_24hr?"23":"12"),w.hourElement.setAttribute("maxlength","2"),w.minuteElement.setAttribute("min","0"),w.minuteElement.setAttribute("max","59"),w.minuteElement.setAttribute("maxlength","2"),w.timeContainer.appendChild(n),w.timeContainer.appendChild(t),w.timeContainer.appendChild(a),w.config.time_24hr&&w.timeContainer.classList.add("time24hr");if(w.config.enableSeconds){w.timeContainer.classList.add("hasSeconds");var i=m("flatpickr-second");w.secondElement=i.getElementsByTagName("input")[0],w.secondElement.value=o(w.latestSelectedDateObj?w.latestSelectedDateObj.getSeconds():e.seconds),w.secondElement.setAttribute("step",w.minuteElement.getAttribute("step")),w.secondElement.setAttribute("min","0"),w.secondElement.setAttribute("max","59"),w.secondElement.setAttribute("maxlength","2"),w.timeContainer.appendChild(s("span","flatpickr-time-separator",":")),w.timeContainer.appendChild(i)}w.config.time_24hr||(w.amPM=s("span","flatpickr-am-pm",w.l10n.amPM[r((w.latestSelectedDateObj?w.hourElement.value:w.config.defaultHour)>11)]),w.amPM.title=w.l10n.toggleTitle,w.amPM.tabIndex=-1,w.timeContainer.appendChild(w.amPM));return w.timeContainer}());d(w.calendarContainer,"rangeMode","range"===w.config.mode),d(w.calendarContainer,"animate",!0===w.config.animate),d(w.calendarContainer,"multiMonth",w.config.showMonths>1),w.calendarContainer.appendChild(e);var i=void 0!==w.config.appendTo&&void 0!==w.config.appendTo.nodeType;if((w.config.inline||w.config.static)&&(w.calendarContainer.classList.add(w.config.inline?"inline":"static"),w.config.inline&&(!i&&w.element.parentNode?w.element.parentNode.insertBefore(w.calendarContainer,w._input.nextSibling):void 0!==w.config.appendTo&&w.config.appendTo.appendChild(w.calendarContainer)),w.config.static)){var l=s("div","flatpickr-wrapper");w.element.parentNode&&w.element.parentNode.insertBefore(l,w.element),l.appendChild(w.element),w.altInput&&l.appendChild(w.altInput),l.appendChild(w.calendarContainer)}w.config.static||w.config.inline||(void 0!==w.config.appendTo?w.config.appendTo:window.document.body).appendChild(w.calendarContainer)}(),function(){w.config.wrap&&["open","close","toggle","clear"].forEach((function(e){Array.prototype.forEach.call(w.element.querySelectorAll("[data-"+e+"]"),(function(t){return A(t,"click",w[e])}))}));if(w.isMobile)return void function(){var e=w.config.enableTime?w.config.noCalendar?"time":"datetime-local":"date";w.mobileInput=s("input",w.input.className+" flatpickr-mobile"),w.mobileInput.tabIndex=1,w.mobileInput.type=e,w.mobileInput.disabled=w.input.disabled,w.mobileInput.required=w.input.required,w.mobileInput.placeholder=w.input.placeholder,w.mobileFormatStr="datetime-local"===e?"Y-m-d\\TH:i:S":"date"===e?"Y-m-d":"H:i:S",w.selectedDates.length>0&&(w.mobileInput.defaultValue=w.mobileInput.value=w.formatDate(w.selectedDates[0],w.mobileFormatStr));w.config.minDate&&(w.mobileInput.min=w.formatDate(w.config.minDate,"Y-m-d"));w.config.maxDate&&(w.mobileInput.max=w.formatDate(w.config.maxDate,"Y-m-d"));w.input.getAttribute("step")&&(w.mobileInput.step=String(w.input.getAttribute("step")));w.input.type="hidden",void 0!==w.altInput&&(w.altInput.type="hidden");try{w.input.parentNode&&w.input.parentNode.insertBefore(w.mobileInput,w.input.nextSibling)}catch(e){}A(w.mobileInput,"change",(function(e){w.setDate(g(e).value,!1,w.mobileFormatStr),pe("onChange"),pe("onClose")}))}();var e=l(ie,50);w._debouncedChange=l(N,300),w.daysContainer&&!/iPhone|iPad|iPod/i.test(navigator.userAgent)&&A(w.daysContainer,"mouseover",(function(e){"range"===w.config.mode&&ae(g(e))}));A(window.document.body,"keydown",ne),w.config.inline||w.config.static||A(window,"resize",e);void 0!==window.ontouchstart?A(window.document,"touchstart",Z):A(window.document,"mousedown",Z);A(window.document,"focus",Z,{capture:!0}),!0===w.config.clickOpens&&(A(w._input,"focus",w.open),A(w._input,"click",w.open));void 0!==w.daysContainer&&(A(w.monthNav,"click",Ce),A(w.monthNav,["keyup","increment"],F),A(w.daysContainer,"click",ue));if(void 0!==w.timeContainer&&void 0!==w.minuteElement&&void 0!==w.hourElement){var t=function(e){return g(e).select()};A(w.timeContainer,["increment"],I),A(w.timeContainer,"blur",I,{capture:!0}),A(w.timeContainer,"click",Y),A([w.hourElement,w.minuteElement],["focus","click"],t),void 0!==w.secondElement&&A(w.secondElement,"focus",(function(){return w.secondElement&&w.secondElement.select()})),void 0!==w.amPM&&A(w.amPM,"click",(function(e){I(e),N()}))}w.config.allowInput&&A(w._input,"blur",te)}(),(w.selectedDates.length||w.config.noCalendar)&&(w.config.enableTime&&_(w.config.noCalendar?w.latestSelectedDateObj:void 0),be(!1)),k();var t=/^((?!chrome|android).)*safari/i.test(navigator.userAgent);!w.isMobile&&t&&ce(),pe("onReady")}(),w}function k(e,t){for(var n=Array.prototype.slice.call(e).filter((function(e){return e instanceof HTMLElement})),a=[],i=0;i 0 && arguments[0] !== undefined ? arguments[0] : {}; + + return new Growl(settings); + } + }] + ); + + function Growl() + { + var settings = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; + + _classCallCheck(this, Growl); + + this.render = this.render.bind(this); + this.bind = this.bind.bind(this); + this.unbind = this.unbind.bind(this); + this.mouseEnter = this.mouseEnter.bind(this); + this.mouseLeave = this.mouseLeave.bind(this); + this.click = this.click.bind(this); + this.close = this.close.bind(this); + this.cycle = this.cycle.bind(this); + this.waitAndDismiss = this.waitAndDismiss.bind(this); + this.present = this.present.bind(this); + this.dismiss = this.dismiss.bind(this); + this.remove = this.remove.bind(this); + this.animate = this.animate.bind(this); + this.$growls = this.$growls.bind(this); + this.$growl = this.$growl.bind(this); + this.html = this.html.bind(this); + this.content = this.content.bind(this); + this.container = this.container.bind(this); + this.settings = $.extend({}, Growl.settings, settings); + this.initialize(this.settings.location); + this.render(); + } + + _createClass( + Growl, [{ + key: "initialize", + value: function initialize(location) + { + var id; + id = 'growls-' + location; + return $('body:not(:has(#' + id + '))').append('
            '); + } + }, { + key: "render", + value: function render() + { + var $growl; + $growl = this.$growl(); + this.$growls(this.settings.location).append($growl); + if (this.settings.fixed) { + this.present(); + } else { + this.cycle(); + } + } + }, { + key: "bind", + value: function bind() + { + var $growl = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.$growl(); + + $growl.on("click", this.click); + if (this.settings.delayOnHover) { + $growl.on("mouseenter", this.mouseEnter); + $growl.on("mouseleave", this.mouseLeave); + } + return $growl.on("contextmenu", this.close).find("." + this.settings.namespace + "-close").on("click", this.close); + } + }, { + key: "unbind", + value: function unbind() + { + var $growl = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.$growl(); + + $growl.off("click", this.click); + if (this.settings.delayOnHover) { + $growl.off("mouseenter", this.mouseEnter); + $growl.off("mouseleave", this.mouseLeave); + } + return $growl.off("contextmenu", this.close).find("." + this.settings.namespace + "-close").off("click", this.close); + } + }, { + key: "mouseEnter", + value: function mouseEnter(event) + { + var $growl; + $growl = this.$growl(); + return $growl.stop(true, true); + } + }, { + key: "mouseLeave", + value: function mouseLeave(event) + { + return this.waitAndDismiss(); + } + }, { + key: "click", + value: function click(event) + { + if (this.settings.url != null) { + event.preventDefault(); + event.stopPropagation(); + return window.open(this.settings.url); + } + } + }, { + key: "close", + value: function close(event) + { + var $growl; + event.preventDefault(); + event.stopPropagation(); + $growl = this.$growl(); + return $growl.stop().queue(this.dismiss).queue(this.remove); + } + }, { + key: "cycle", + value: function cycle() + { + var $growl; + $growl = this.$growl(); + return $growl.queue(this.present).queue(this.waitAndDismiss()); + } + }, { + key: "waitAndDismiss", + value: function waitAndDismiss() + { + var $growl; + $growl = this.$growl(); + return $growl.delay(this.settings.duration).queue(this.dismiss).queue(this.remove); + } + }, { + key: "present", + value: function present(callback) + { + var $growl; + $growl = this.$growl(); + this.bind($growl); + return this.animate($growl, this.settings.namespace + "-incoming", 'out', callback); + } + }, { + key: "dismiss", + value: function dismiss(callback) + { + var $growl; + $growl = this.$growl(); + this.unbind($growl); + return this.animate($growl, this.settings.namespace + "-outgoing", 'in', callback); + } + }, { + key: "remove", + value: function remove(callback) + { + this.$growl().remove(); + return typeof callback === "function" ? callback() : void 0; + } + }, { + key: "animate", + value: function animate($element, name) + { + var direction = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'in'; + var callback = arguments[3]; + + var transition; + transition = Animation.transition($element); + $element[direction === 'in' ? 'removeClass' : 'addClass'](name); + $element.offset().position; + $element[direction === 'in' ? 'addClass' : 'removeClass'](name); + if (callback == null) { + return; + } + if (transition != null) { + $element.one(transition, callback); + } else { + callback(); + } + } + }, { + key: "$growls", + value: function $growls(location) + { + var base; + if (this.$_growls == null) { + this.$_growls = []; + } + return (base = this.$_growls)[location] != null ? base[location] : base[location] = $('#growls-' + location); + } + }, { + key: "$growl", + value: function $growl() + { + return this.$_growl != null ? this.$_growl : this.$_growl = $(this.html()); + } + }, { + key: "html", + value: function html() + { + return this.container(this.content()); + } + }, { + key: "content", + value: function content() + { + return "
            " + this.settings.close + "
            \n
            " + this.settings.title + "
            \n
            " + this.settings.message + "
            "; + } + }, { + key: "container", + value: function container(content) + { + return "
            \n " + content + "\n
            "; + } + }] + ); + + return Growl; + }(); + + ; + + Growl.settings = { + namespace: 'growl', + duration: 3200, + close: "×", + location: "default", + style: "default", + size: "medium", + delayOnHover: true + }; + + return Growl; + }(); + + this.Growl = Growl; + + $.growl = function () { + var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; + + return Growl.growl(options); + }; + + $.growl.error = function () { + var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; + + var settings; + settings = { + title: "Error!", + style: "error" + }; + return $.growl($.extend(settings, options)); + }; + + $.growl.notice = function () { + var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; + + var settings; + settings = { + title: "Notice!", + style: "notice" + }; + return $.growl($.extend(settings, options)); + }; + + $.growl.warning = function () { + var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; + + var settings; + settings = { + title: "Warning!", + style: "warning" + }; + return $.growl($.extend(settings, options)); + }; +}).call(this); \ No newline at end of file diff --git a/js/vendor/jquery-3.5.1.min.js b/src/js/vendor/jquery.min.js similarity index 100% rename from js/vendor/jquery-3.5.1.min.js rename to src/js/vendor/jquery.min.js diff --git a/src/js/vendor/jquery.timeago.js b/src/js/vendor/jquery.timeago.js new file mode 100644 index 0000000..7e341f5 --- /dev/null +++ b/src/js/vendor/jquery.timeago.js @@ -0,0 +1,242 @@ +/** + * Timeago is a jQuery plugin that makes it easy to support automatically + * updating fuzzy timestamps (e.g. "4 minutes ago" or "about 1 day ago"). + * + * @name timeago + * @version 1.6.7 + * @requires jQuery >=1.5.0 <4.0 + * @author Ryan McGeary + * @license MIT License - http://www.opensource.org/licenses/mit-license.php + * + * For usage and examples, visit: + * http://timeago.yarp.com/ + * + * Copyright (c) 2008-2019, Ryan McGeary (ryan -[at]- mcgeary [*dot*] org) + */ + +(function (factory) { + if (typeof define === 'function' && define.amd) { + // AMD. Register as an anonymous module. + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + // Browser globals + factory(jQuery); + } +}(function ($) { + $.timeago = function (timestamp) { + if (timestamp instanceof Date) { + return inWords(timestamp); + } else if (typeof timestamp === "string") { + return inWords($.timeago.parse(timestamp)); + } else if (typeof timestamp === "number") { + return inWords(new Date(timestamp)); + } else { + return inWords($.timeago.datetime(timestamp)); + } + }; + var $t = $.timeago; + + $.extend( + $.timeago, { + settings: { + refreshMillis: 60000, + allowPast: true, + allowFuture: false, + localeTitle: false, + cutoff: 0, + autoDispose: true, + strings: { + prefixAgo: null, + prefixFromNow: null, + suffixAgo: "ago", + suffixFromNow: "from now", + inPast: "any moment now", + seconds: "less than a minute", + minute: "about a minute", + minutes: "%d minutes", + hour: "about an hour", + hours: "about %d hours", + day: "a day", + days: "%d days", + month: "about a month", + months: "%d months", + year: "about a year", + years: "%d years", + wordSeparator: " ", + numbers: [] + } + }, + + inWords: function (distanceMillis) { + if (!this.settings.allowPast && ! this.settings.allowFuture) { + throw 'timeago allowPast and allowFuture settings can not both be set to false.'; + } + + var $l = this.settings.strings; + var prefix = $l.prefixAgo; + var suffix = $l.suffixAgo; + if (this.settings.allowFuture) { + if (distanceMillis < 0) { + prefix = $l.prefixFromNow; + suffix = $l.suffixFromNow; + } + } + + if (!this.settings.allowPast && distanceMillis >= 0) { + return this.settings.strings.inPast; + } + + var seconds = Math.abs(distanceMillis) / 1000; + var minutes = seconds / 60; + var hours = minutes / 60; + var days = hours / 24; + var years = days / 365; + + function substitute(stringOrFunction, number) + { + var string = $.isFunction(stringOrFunction) ? stringOrFunction(number, distanceMillis) : stringOrFunction; + var value = ($l.numbers && $l.numbers[number]) || number; + return string.replace(/%d/i, value); + } + + var words = seconds < 45 && substitute($l.seconds, Math.round(seconds)) || + seconds < 90 && substitute($l.minute, 1) || + minutes < 45 && substitute($l.minutes, Math.round(minutes)) || + minutes < 90 && substitute($l.hour, 1) || + hours < 24 && substitute($l.hours, Math.round(hours)) || + hours < 42 && substitute($l.day, 1) || + days < 30 && substitute($l.days, Math.round(days)) || + days < 45 && substitute($l.month, 1) || + days < 365 && substitute($l.months, Math.round(days / 30)) || + years < 1.5 && substitute($l.year, 1) || + substitute($l.years, Math.round(years)); + + var separator = $l.wordSeparator || ""; + if ($l.wordSeparator === undefined) { + separator = " "; } + return $.trim([prefix, words, suffix].join(separator)); + }, + + parse: function (iso8601) { + var s = $.trim(iso8601); + s = s.replace(/\.\d+/,""); // remove milliseconds + s = s.replace(/-/,"/").replace(/-/,"/"); + s = s.replace(/T/," ").replace(/Z/," UTC"); + s = s.replace(/([\+\-]\d\d)\:?(\d\d)/," $1$2"); // -04:00 -> -0400 + s = s.replace(/([\+\-]\d\d)$/," $100"); // +09 -> +0900 + return new Date(s); + }, + datetime: function (elem) { + var iso8601 = $t.isTime(elem) ? $(elem).attr("datetime") : $(elem).attr("title"); + return $t.parse(iso8601); + }, + isTime: function (elem) { + // jQuery's `is()` doesn't play well with HTML5 in IE + return $(elem).get(0).tagName.toLowerCase() === "time"; // $(elem).is("time"); + } + } + ); + + // functions that can be called via $(el).timeago('action') + // init is default when no action is given + // functions are called with context of a single element + var functions = { + init: function () { + functions.dispose.call(this); + var refresh_el = $.proxy(refresh, this); + refresh_el(); + var $s = $t.settings; + if ($s.refreshMillis > 0) { + this._timeagoInterval = setInterval(refresh_el, $s.refreshMillis); + } + }, + update: function (timestamp) { + var date = (timestamp instanceof Date) ? timestamp : $t.parse(timestamp); + $(this).data('timeago', { datetime: date }); + if ($t.settings.localeTitle) { + $(this).attr("title", date.toLocaleString()); + } + refresh.apply(this); + }, + updateFromDOM: function () { + $(this).data('timeago', { datetime: $t.parse($t.isTime(this) ? $(this).attr("datetime") : $(this).attr("title")) }); + refresh.apply(this); + }, + dispose: function () { + if (this._timeagoInterval) { + window.clearInterval(this._timeagoInterval); + this._timeagoInterval = null; + } + } + }; + + $.fn.timeago = function (action, options) { + var fn = action ? functions[action] : functions.init; + if (!fn) { + throw new Error("Unknown function name '" + action + "' for timeago"); + } + // each over objects here and call the requested function + this.each( + function () { + fn.call(this, options); + } + ); + return this; + }; + + function refresh() + { + var $s = $t.settings; + + //check if it's still visible + if ($s.autoDispose && !$.contains(document.documentElement,this)) { + //stop if it has been removed + $(this).timeago("dispose"); + return this; + } + + var data = prepareData(this); + + if (!isNaN(data.datetime)) { + if ($s.cutoff === 0 || Math.abs(distance(data.datetime)) < $s.cutoff) { + $(this).text(inWords(data.datetime)); + } else { + if ($(this).attr('title').length > 0) { + $(this).text($(this).attr('title')); + } + } + } + return this; + } + + function prepareData(element) + { + element = $(element); + if (!element.data("timeago")) { + element.data("timeago", { datetime: $t.datetime(element) }); + var text = $.trim(element.text()); + if ($t.settings.localeTitle) { + element.attr("title", element.data('timeago').datetime.toLocaleString()); + } else if (text.length > 0 && !($t.isTime(element) && element.attr("title"))) { + element.attr("title", text); + } + } + return element.data("timeago"); + } + + function inWords(date) + { + return $t.inWords(distance(date)); + } + + function distance(date) + { + return (new Date().getTime() - date.getTime()); + } + + // fix for IE6 suckage + document.createElement("abbr"); + document.createElement("time"); +})); diff --git a/locale/cs_CZ/LC_MESSAGES/server-status.mo b/src/locale/cs_CZ/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/cs_CZ/LC_MESSAGES/server-status.mo rename to src/locale/cs_CZ/LC_MESSAGES/server-status.mo diff --git a/locale/cs_CZ/LC_MESSAGES/server-status.po b/src/locale/cs_CZ/LC_MESSAGES/server-status.po similarity index 100% rename from locale/cs_CZ/LC_MESSAGES/server-status.po rename to src/locale/cs_CZ/LC_MESSAGES/server-status.po diff --git a/locale/cs_CZ/flag.png b/src/locale/cs_CZ/flag.png similarity index 100% rename from locale/cs_CZ/flag.png rename to src/locale/cs_CZ/flag.png diff --git a/src/locale/cs_CZ/jquery.timeago.js b/src/locale/cs_CZ/jquery.timeago.js new file mode 100644 index 0000000..9edd268 --- /dev/null +++ b/src/locale/cs_CZ/jquery.timeago.js @@ -0,0 +1,46 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Czech + (function () { + function f(n, d, a) + { + return a[d >= 0 ? 0 : a.length === 2 || n < 5 ? 1 : 2]; + } + + jQuery.timeago.settings.strings = { + prefixAgo: 'před', + prefixFromNow: 'za', + suffixAgo: null, + suffixFromNow: null, + seconds: function (n, d) { + return f(n, d, ['méně než minutou', 'méně než minutu']);}, + minute: function (n, d) { + return f(n, d, ['minutou', 'minutu']);}, + minutes: function (n, d) { + return f(n, d, ['%d minutami', '%d minuty', '%d minut']);}, + hour: function (n, d) { + return f(n, d, ['hodinou', 'hodinu']);}, + hours: function (n, d) { + return f(n, d, ['%d hodinami', '%d hodiny', '%d hodin']);}, + day: function (n, d) { + return f(n, d, ['%d dnem', '%d den']);}, + days: function (n, d) { + return f(n, d, ['%d dny', '%d dny', '%d dní']);}, + month: function (n, d) { + return f(n, d, ['%d měsícem', '%d měsíc']);}, + months: function (n, d) { + return f(n, d, ['%d měsíci', '%d měsíce', '%d měsíců']);}, + year: function (n, d) { + return f(n, d, ['%d rokem', '%d rok']);}, + years: function (n, d) { + return f(n, d, ['%d lety', '%d roky', '%d let']);} + }; + })(); +})); diff --git a/locale/da_DK/LC_MESSAGES/server-status.mo b/src/locale/da_DK/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/da_DK/LC_MESSAGES/server-status.mo rename to src/locale/da_DK/LC_MESSAGES/server-status.mo diff --git a/locale/da_DK/LC_MESSAGES/server-status.po b/src/locale/da_DK/LC_MESSAGES/server-status.po similarity index 100% rename from locale/da_DK/LC_MESSAGES/server-status.po rename to src/locale/da_DK/LC_MESSAGES/server-status.po diff --git a/locale/da_DK/flag.png b/src/locale/da_DK/flag.png similarity index 100% rename from locale/da_DK/flag.png rename to src/locale/da_DK/flag.png diff --git a/src/locale/da_DK/jquery.timeago.js b/src/locale/da_DK/jquery.timeago.js new file mode 100644 index 0000000..0192321 --- /dev/null +++ b/src/locale/da_DK/jquery.timeago.js @@ -0,0 +1,28 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Danish + jQuery.timeago.settings.strings = { + prefixAgo: "for", + prefixFromNow: "om", + suffixAgo: "siden", + suffixFromNow: "", + seconds: "mindre end et minut", + minute: "ca. et minut", + minutes: "%d minutter", + hour: "ca. en time", + hours: "ca. %d timer", + day: "en dag", + days: "%d dage", + month: "ca. en måned", + months: "%d måneder", + year: "ca. et år", + years: "%d år" + }; +})); diff --git a/locale/de_DE/LC_MESSAGES/server-status.mo b/src/locale/de_DE/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/de_DE/LC_MESSAGES/server-status.mo rename to src/locale/de_DE/LC_MESSAGES/server-status.mo diff --git a/locale/de_DE/LC_MESSAGES/server-status.po b/src/locale/de_DE/LC_MESSAGES/server-status.po similarity index 100% rename from locale/de_DE/LC_MESSAGES/server-status.po rename to src/locale/de_DE/LC_MESSAGES/server-status.po diff --git a/locale/de_DE/flag.png b/src/locale/de_DE/flag.png similarity index 100% rename from locale/de_DE/flag.png rename to src/locale/de_DE/flag.png diff --git a/src/locale/de_DE/jquery.timeago.js b/src/locale/de_DE/jquery.timeago.js new file mode 100644 index 0000000..6ec9ed0 --- /dev/null +++ b/src/locale/de_DE/jquery.timeago.js @@ -0,0 +1,28 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // German + jQuery.timeago.settings.strings = { + prefixAgo: "vor", + prefixFromNow: "in", + suffixAgo: "", + suffixFromNow: "", + seconds: "wenigen Sekunden", + minute: "etwa einer Minute", + minutes: "%d Minuten", + hour: "etwa einer Stunde", + hours: "%d Stunden", + day: "etwa einem Tag", + days: "%d Tagen", + month: "etwa einem Monat", + months: "%d Monaten", + year: "etwa einem Jahr", + years: "%d Jahren" + }; +})); diff --git a/locale/en_GB/LC_MESSAGES/server-status.mo b/src/locale/en_GB/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/en_GB/LC_MESSAGES/server-status.mo rename to src/locale/en_GB/LC_MESSAGES/server-status.mo diff --git a/locale/en_GB/LC_MESSAGES/server-status.po b/src/locale/en_GB/LC_MESSAGES/server-status.po similarity index 100% rename from locale/en_GB/LC_MESSAGES/server-status.po rename to src/locale/en_GB/LC_MESSAGES/server-status.po diff --git a/locale/en_GB/flag.png b/src/locale/en_GB/flag.png similarity index 100% rename from locale/en_GB/flag.png rename to src/locale/en_GB/flag.png diff --git a/src/locale/en_GB/jquery.timeago.js b/src/locale/en_GB/jquery.timeago.js new file mode 100644 index 0000000..fcc6e0b --- /dev/null +++ b/src/locale/en_GB/jquery.timeago.js @@ -0,0 +1,30 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // English (Template) + jQuery.timeago.settings.strings = { + prefixAgo: null, + prefixFromNow: null, + suffixAgo: "ago", + suffixFromNow: "from now", + seconds: "less than a minute", + minute: "about a minute", + minutes: "%d minutes", + hour: "about an hour", + hours: "about %d hours", + day: "a day", + days: "%d days", + month: "about a month", + months: "%d months", + year: "about a year", + years: "%d years", + wordSeparator: " ", + numbers: [] + }; +})); diff --git a/locale/es_ES/LC_MESSAGES/server-status.mo b/src/locale/es_ES/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/es_ES/LC_MESSAGES/server-status.mo rename to src/locale/es_ES/LC_MESSAGES/server-status.mo diff --git a/locale/es_ES/LC_MESSAGES/server-status.po b/src/locale/es_ES/LC_MESSAGES/server-status.po similarity index 100% rename from locale/es_ES/LC_MESSAGES/server-status.po rename to src/locale/es_ES/LC_MESSAGES/server-status.po diff --git a/locale/es_ES/flag.png b/src/locale/es_ES/flag.png similarity index 100% rename from locale/es_ES/flag.png rename to src/locale/es_ES/flag.png diff --git a/src/locale/es_ES/jquery.timeago.js b/src/locale/es_ES/jquery.timeago.js new file mode 100644 index 0000000..d2a1ade --- /dev/null +++ b/src/locale/es_ES/jquery.timeago.js @@ -0,0 +1,29 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Spanish + jQuery.timeago.settings.strings = { + prefixAgo: "hace", + prefixFromNow: "dentro de", + suffixAgo: "", + suffixFromNow: "", + seconds: "menos de un minuto", + minute: "un minuto", + minutes: "unos %d minutos", + hour: "una hora", + hours: "%d horas", + day: "un día", + days: "%d días", + month: "un mes", + months: "%d meses", + year: "un año", + years: "%d años" + }; +})); + diff --git a/locale/fr_FR/LC_MESSAGES/server-status.mo b/src/locale/fr_FR/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/fr_FR/LC_MESSAGES/server-status.mo rename to src/locale/fr_FR/LC_MESSAGES/server-status.mo diff --git a/locale/fr_FR/LC_MESSAGES/server-status.po b/src/locale/fr_FR/LC_MESSAGES/server-status.po similarity index 100% rename from locale/fr_FR/LC_MESSAGES/server-status.po rename to src/locale/fr_FR/LC_MESSAGES/server-status.po diff --git a/locale/fr_FR/flag.png b/src/locale/fr_FR/flag.png similarity index 100% rename from locale/fr_FR/flag.png rename to src/locale/fr_FR/flag.png diff --git a/src/locale/fr_FR/jquery.timeago.js b/src/locale/fr_FR/jquery.timeago.js new file mode 100644 index 0000000..d1824dd --- /dev/null +++ b/src/locale/fr_FR/jquery.timeago.js @@ -0,0 +1,27 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // French + jQuery.timeago.settings.strings = { + // environ ~= about, it's optional + prefixAgo: "il y a", + prefixFromNow: "d'ici", + seconds: "moins d'une minute", + minute: "environ une minute", + minutes: "environ %d minutes", + hour: "environ une heure", + hours: "environ %d heures", + day: "environ un jour", + days: "environ %d jours", + month: "environ un mois", + months: "environ %d mois", + year: "un an", + years: "%d ans" + }; +})); diff --git a/locale/it_IT/LC_MESSAGES/server-status.mo b/src/locale/it_IT/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/it_IT/LC_MESSAGES/server-status.mo rename to src/locale/it_IT/LC_MESSAGES/server-status.mo diff --git a/locale/it_IT/LC_MESSAGES/server-status.po b/src/locale/it_IT/LC_MESSAGES/server-status.po similarity index 100% rename from locale/it_IT/LC_MESSAGES/server-status.po rename to src/locale/it_IT/LC_MESSAGES/server-status.po diff --git a/locale/it_IT/flag.png b/src/locale/it_IT/flag.png similarity index 100% rename from locale/it_IT/flag.png rename to src/locale/it_IT/flag.png diff --git a/src/locale/it_IT/jquery.timeago.js b/src/locale/it_IT/jquery.timeago.js new file mode 100644 index 0000000..f63624d --- /dev/null +++ b/src/locale/it_IT/jquery.timeago.js @@ -0,0 +1,26 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Italian + jQuery.timeago.settings.strings = { + suffixAgo: "fa", + suffixFromNow: "da ora", + seconds: "meno di un minuto", + minute: "circa un minuto", + minutes: "%d minuti", + hour: "circa un'ora", + hours: "circa %d ore", + day: "un giorno", + days: "%d giorni", + month: "circa un mese", + months: "%d mesi", + year: "circa un anno", + years: "%d anni" + }; +})); diff --git a/locale/lt_LT/LC_MESSAGES/server-status.mo b/src/locale/lt_LT/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/lt_LT/LC_MESSAGES/server-status.mo rename to src/locale/lt_LT/LC_MESSAGES/server-status.mo diff --git a/locale/lt_LT/LC_MESSAGES/server-status.po b/src/locale/lt_LT/LC_MESSAGES/server-status.po similarity index 100% rename from locale/lt_LT/LC_MESSAGES/server-status.po rename to src/locale/lt_LT/LC_MESSAGES/server-status.po diff --git a/locale/lt_LT/flag.png b/src/locale/lt_LT/flag.png similarity index 100% rename from locale/lt_LT/flag.png rename to src/locale/lt_LT/flag.png diff --git a/src/locale/lt_LT/jquery.timeago.js b/src/locale/lt_LT/jquery.timeago.js new file mode 100644 index 0000000..f8fe363 --- /dev/null +++ b/src/locale/lt_LT/jquery.timeago.js @@ -0,0 +1,30 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + //Lithuanian + jQuery.timeago.settings.strings = { + prefixAgo: "prieš", + prefixFromNow: null, + suffixAgo: null, + suffixFromNow: "nuo dabar", + seconds: "%d sek.", + minute: "min.", + minutes: "%d min.", + hour: "val.", + hours: "%d val.", + day: "1 d.", + days: "%d d.", + month: "mėn.", + months: "%d mėn.", + year: "metus", + years: "%d metus", + wordSeparator: " ", + numbers: [] + }; +})); diff --git a/locale/nb_NO/LC_MESSAGES/server-status.mo b/src/locale/nb_NO/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/nb_NO/LC_MESSAGES/server-status.mo rename to src/locale/nb_NO/LC_MESSAGES/server-status.mo diff --git a/locale/nb_NO/LC_MESSAGES/server-status.po b/src/locale/nb_NO/LC_MESSAGES/server-status.po similarity index 100% rename from locale/nb_NO/LC_MESSAGES/server-status.po rename to src/locale/nb_NO/LC_MESSAGES/server-status.po diff --git a/locale/nb_NO/flag.png b/src/locale/nb_NO/flag.png similarity index 100% rename from locale/nb_NO/flag.png rename to src/locale/nb_NO/flag.png diff --git a/src/locale/nb_NO/jquery.timeago.js b/src/locale/nb_NO/jquery.timeago.js new file mode 100644 index 0000000..3a1691f --- /dev/null +++ b/src/locale/nb_NO/jquery.timeago.js @@ -0,0 +1,30 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Norsk + jQuery.timeago.settings.strings = { + prefixAgo: null, + prefixFromNow: null, + suffixAgo: "siden", + suffixFromNow: "fra nå", + seconds: "mindre en ett minutt", + minute: "ca ett minutt", + minutes: "%d minutter", + hour: "ca en time", + hours: "ca %d timer", + day: "en dag", + days: "%d dager", + month: "ca en måned", + months: "%d måneder", + year: "ca ett år", + years: "%d år", + wordSeparator: " ", + numbers: [] + }; +})); diff --git a/locale/nl_NL/LC_MESSAGES/server-status.mo b/src/locale/nl_NL/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/nl_NL/LC_MESSAGES/server-status.mo rename to src/locale/nl_NL/LC_MESSAGES/server-status.mo diff --git a/locale/nl_NL/LC_MESSAGES/server-status.po b/src/locale/nl_NL/LC_MESSAGES/server-status.po similarity index 100% rename from locale/nl_NL/LC_MESSAGES/server-status.po rename to src/locale/nl_NL/LC_MESSAGES/server-status.po diff --git a/locale/nl_NL/flag.png b/src/locale/nl_NL/flag.png similarity index 100% rename from locale/nl_NL/flag.png rename to src/locale/nl_NL/flag.png diff --git a/src/locale/nl_NL/jquery.timeago.js b/src/locale/nl_NL/jquery.timeago.js new file mode 100644 index 0000000..efa9b47 --- /dev/null +++ b/src/locale/nl_NL/jquery.timeago.js @@ -0,0 +1,30 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Dutch + jQuery.timeago.settings.strings = { + prefixAgo: null, + prefixFromNow: "over", + suffixAgo: "geleden", + suffixFromNow: null, + seconds: "minder dan een minuut", + minute: "ongeveer een minuut", + minutes: "%d minuten", + hour: "ongeveer een uur", + hours: "ongeveer %d uur", + day: "een dag", + days: "%d dagen", + month: "ongeveer een maand", + months: "%d maanden", + year: "ongeveer een jaar", + years: "%d jaar", + wordSeparator: " ", + numbers: [] + }; +})); diff --git a/locale/pl_PL/LC_MESSAGES/server-status.mo b/src/locale/pl_PL/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/pl_PL/LC_MESSAGES/server-status.mo rename to src/locale/pl_PL/LC_MESSAGES/server-status.mo diff --git a/locale/pl_PL/LC_MESSAGES/server-status.po b/src/locale/pl_PL/LC_MESSAGES/server-status.po similarity index 100% rename from locale/pl_PL/LC_MESSAGES/server-status.po rename to src/locale/pl_PL/LC_MESSAGES/server-status.po diff --git a/locale/pl_PL/flag.png b/src/locale/pl_PL/flag.png similarity index 100% rename from locale/pl_PL/flag.png rename to src/locale/pl_PL/flag.png diff --git a/src/locale/pl_PL/jquery.timeago.js b/src/locale/pl_PL/jquery.timeago.js new file mode 100644 index 0000000..37c4160 --- /dev/null +++ b/src/locale/pl_PL/jquery.timeago.js @@ -0,0 +1,44 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Polish + function numpf(n, s, t) + { + // s - 2-4, 22-24, 32-34 ... + // t - 5-21, 25-31, ... + var n10 = n % 10; + if ((n10 > 1) && (n10 < 5) && ( (n > 20) || (n < 10) ) ) { + return s; + } else { + return t; + } + } + + jQuery.timeago.settings.strings = { + prefixAgo: null, + prefixFromNow: "za", + suffixAgo: "temu", + suffixFromNow: null, + seconds: "mniej niż minutę", + minute: "minutę", + minutes: function (value) { + return numpf(value, "%d minuty", "%d minut"); }, + hour: "godzinę", + hours: function (value) { + return numpf(value, "%d godziny", "%d godzin"); }, + day: "dzień", + days: "%d dni", + month: "miesiąc", + months: function (value) { + return numpf(value, "%d miesiące", "%d miesięcy"); }, + year: "rok", + years: function (value) { + return numpf(value, "%d lata", "%d lat"); } + }; +})); diff --git a/locale/pt_BR/LC_MESSAGES/server-status.mo b/src/locale/pt_BR/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/pt_BR/LC_MESSAGES/server-status.mo rename to src/locale/pt_BR/LC_MESSAGES/server-status.mo diff --git a/locale/pt_BR/LC_MESSAGES/server-status.po b/src/locale/pt_BR/LC_MESSAGES/server-status.po similarity index 100% rename from locale/pt_BR/LC_MESSAGES/server-status.po rename to src/locale/pt_BR/LC_MESSAGES/server-status.po diff --git a/locale/pt_BR/flag.png b/src/locale/pt_BR/flag.png similarity index 100% rename from locale/pt_BR/flag.png rename to src/locale/pt_BR/flag.png diff --git a/src/locale/pt_BR/jquery.timeago.js b/src/locale/pt_BR/jquery.timeago.js new file mode 100644 index 0000000..2cddde4 --- /dev/null +++ b/src/locale/pt_BR/jquery.timeago.js @@ -0,0 +1,28 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Brazilian Portuguese + jQuery.timeago.settings.strings = { + prefixAgo: "há", + prefixFromNow: "em", + suffixAgo: null, + suffixFromNow: null, + seconds: "alguns segundos", + minute: "um minuto", + minutes: "%d minutos", + hour: "uma hora", + hours: "%d horas", + day: "um dia", + days: "%d dias", + month: "um mês", + months: "%d meses", + year: "um ano", + years: "%d anos" + }; +})); diff --git a/locale/sk_SK/LC_MESSAGES/server-status.mo b/src/locale/sk_SK/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/sk_SK/LC_MESSAGES/server-status.mo rename to src/locale/sk_SK/LC_MESSAGES/server-status.mo diff --git a/locale/sk_SK/LC_MESSAGES/server-status.po b/src/locale/sk_SK/LC_MESSAGES/server-status.po similarity index 100% rename from locale/sk_SK/LC_MESSAGES/server-status.po rename to src/locale/sk_SK/LC_MESSAGES/server-status.po diff --git a/locale/sk_SK/flag.png b/src/locale/sk_SK/flag.png similarity index 100% rename from locale/sk_SK/flag.png rename to src/locale/sk_SK/flag.png diff --git a/src/locale/sk_SK/jquery.timeago.js b/src/locale/sk_SK/jquery.timeago.js new file mode 100644 index 0000000..c402352 --- /dev/null +++ b/src/locale/sk_SK/jquery.timeago.js @@ -0,0 +1,46 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Slovak + (function () { + function f(n, d, a) + { + return a[d >= 0 ? 0 : a.length === 2 || n < 5 ? 1 : 2]; + } + + jQuery.timeago.settings.strings = { + prefixAgo: 'pred', + prefixFromNow: 'o', + suffixAgo: null, + suffixFromNow: null, + seconds: function (n, d) { + return f(n, d, ['menej ako minútou', 'menej ako minútu']);}, + minute: function (n, d) { + return f(n, d, ['minútou', 'minútu']);}, + minutes: function (n, d) { + return f(n, d, ['%d minútami', '%d minúty', '%d minút']);}, + hour: function (n, d) { + return f(n, d, ['hodinou', 'hodinu']);}, + hours: function (n, d) { + return f(n, d, ['%d hodinami', '%d hodiny', '%d hodín']);}, + day: function (n, d) { + return f(n, d, ['%d dňom', '%d deň']);}, + days: function (n, d) { + return f(n, d, ['%d dňami', '%d dni', '%d dní']);}, + month: function (n, d) { + return f(n, d, ['%d mesiacom', '%d mesiac']);}, + months: function (n, d) { + return f(n, d, ['%d mesiacmi', '%d mesiace', '%d mesiacov']);}, + year: function (n, d) { + return f(n, d, ['%d rokom', '%d rok']);}, + years: function (n, d) { + return f(n, d, ['%d rokmi', '%d roky', '%d rokov']);} + }; + })(); +})); diff --git a/locale/sr_RS/LC_MESSAGES/server-status.mo b/src/locale/sr_RS/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/sr_RS/LC_MESSAGES/server-status.mo rename to src/locale/sr_RS/LC_MESSAGES/server-status.mo diff --git a/locale/sr_RS/LC_MESSAGES/server-status.po b/src/locale/sr_RS/LC_MESSAGES/server-status.po similarity index 100% rename from locale/sr_RS/LC_MESSAGES/server-status.po rename to src/locale/sr_RS/LC_MESSAGES/server-status.po diff --git a/locale/sr_RS/flag.png b/src/locale/sr_RS/flag.png similarity index 100% rename from locale/sr_RS/flag.png rename to src/locale/sr_RS/flag.png diff --git a/src/locale/sr_RS/jquery.timeago.js b/src/locale/sr_RS/jquery.timeago.js new file mode 100644 index 0000000..6b01326 --- /dev/null +++ b/src/locale/sr_RS/jquery.timeago.js @@ -0,0 +1,54 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Serbian + var numpf = function (n, f, s, t) { + var n10; + n10 = n % 10; + if (n10 === 1 && (n === 1 || n > 20)) { + return f; + } else if (n10 > 1 && n10 < 5 && (n > 20 || n < 10)) { + return s; + } else { + return t; + } + }; + + jQuery.timeago.settings.strings = { + prefixAgo: "пре", + prefixFromNow: "за", + suffixAgo: null, + suffixFromNow: null, + second: "секунд", + seconds: function (value) { + return numpf(value, "%d секунд", "%d секунде", "%d секунди"); + }, + minute: "један минут", + minutes: function (value) { + return numpf(value, "%d минут", "%d минута", "%d минута"); + }, + hour: "један сат", + hours: function (value) { + return numpf(value, "%d сат", "%d сата", "%d сати"); + }, + day: "један дан", + days: function (value) { + return numpf(value, "%d дан", "%d дана", "%d дана"); + }, + month: "месец дана", + months: function (value) { + return numpf(value, "%d месец", "%d месеца", "%d месеци"); + }, + year: "годину дана", + years: function (value) { + return numpf(value, "%d годину", "%d године", "%d година"); + }, + wordSeparator: " " + }; +})); diff --git a/locale/tr_TR/LC_MESSAGES/server-status.mo b/src/locale/tr_TR/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/tr_TR/LC_MESSAGES/server-status.mo rename to src/locale/tr_TR/LC_MESSAGES/server-status.mo diff --git a/locale/tr_TR/LC_MESSAGES/server-status.po b/src/locale/tr_TR/LC_MESSAGES/server-status.po similarity index 100% rename from locale/tr_TR/LC_MESSAGES/server-status.po rename to src/locale/tr_TR/LC_MESSAGES/server-status.po diff --git a/locale/tr_TR/flag.png b/src/locale/tr_TR/flag.png similarity index 100% rename from locale/tr_TR/flag.png rename to src/locale/tr_TR/flag.png diff --git a/src/locale/tr_TR/jquery.timeago.js b/src/locale/tr_TR/jquery.timeago.js new file mode 100644 index 0000000..06e0e44 --- /dev/null +++ b/src/locale/tr_TR/jquery.timeago.js @@ -0,0 +1,26 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Turkish + jQuery.timeago.settings.strings = { + suffixAgo: 'önce', + suffixFromNow: null, + seconds: 'birkaç saniye', + minute: '1 dakika', + minutes: '%d dakika', + hour: '1 saat', + hours: '%d saat', + day: '1 gün', + days: '%d gün', + month: '1 ay', + months: '%d ay', + year: '1 yıl', + years: '%d yıl' + }; +})); diff --git a/locale/uk_UA/LC_MESSAGES/server-status.mo b/src/locale/uk_UA/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/uk_UA/LC_MESSAGES/server-status.mo rename to src/locale/uk_UA/LC_MESSAGES/server-status.mo diff --git a/locale/uk_UA/LC_MESSAGES/server-status.po b/src/locale/uk_UA/LC_MESSAGES/server-status.po similarity index 100% rename from locale/uk_UA/LC_MESSAGES/server-status.po rename to src/locale/uk_UA/LC_MESSAGES/server-status.po diff --git a/locale/uk_UA/flag.png b/src/locale/uk_UA/flag.png similarity index 100% rename from locale/uk_UA/flag.png rename to src/locale/uk_UA/flag.png diff --git a/src/locale/uk_UA/jquery.timeago.js b/src/locale/uk_UA/jquery.timeago.js new file mode 100644 index 0000000..5b8aa92 --- /dev/null +++ b/src/locale/uk_UA/jquery.timeago.js @@ -0,0 +1,48 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Ukrainian + function numpf(n, f, s, t) + { + // f - 1, 21, 31, ... + // s - 2-4, 22-24, 32-34 ... + // t - 5-20, 25-30, ... + var n10 = n % 10; + if ((n10 === 1) && ( (n === 1) || (n > 20) ) ) { + return f; + } else if ((n10 > 1) && (n10 < 5) && ( (n > 20) || (n < 10) ) ) { + return s; + } else { + return t; + } + } + + jQuery.timeago.settings.strings = { + prefixAgo: null, + prefixFromNow: "через", + suffixAgo: "тому", + suffixFromNow: null, + seconds: "менше хвилини", + minute: "хвилина", + minutes: function (value) { + return numpf(value, "%d хвилина", "%d хвилини", "%d хвилин"); }, + hour: "година", + hours: function (value) { + return numpf(value, "%d година", "%d години", "%d годин"); }, + day: "день", + days: function (value) { + return numpf(value, "%d день", "%d дні", "%d днів"); }, + month: "місяць", + months: function (value) { + return numpf(value, "%d місяць", "%d місяці", "%d місяців"); }, + year: "рік", + years: function (value) { + return numpf(value, "%d рік", "%d роки", "%d років"); } + }; +})); diff --git a/locale/zh_CN/LC_MESSAGES/server-status.mo b/src/locale/zh_CN/LC_MESSAGES/server-status.mo similarity index 100% rename from locale/zh_CN/LC_MESSAGES/server-status.mo rename to src/locale/zh_CN/LC_MESSAGES/server-status.mo diff --git a/locale/zh_CN/LC_MESSAGES/server-status.po b/src/locale/zh_CN/LC_MESSAGES/server-status.po similarity index 100% rename from locale/zh_CN/LC_MESSAGES/server-status.po rename to src/locale/zh_CN/LC_MESSAGES/server-status.po diff --git a/locale/zh_CN/flag.png b/src/locale/zh_CN/flag.png similarity index 100% rename from locale/zh_CN/flag.png rename to src/locale/zh_CN/flag.png diff --git a/src/locale/zh_CN/jquery.timeago.js b/src/locale/zh_CN/jquery.timeago.js new file mode 100644 index 0000000..bba9c10 --- /dev/null +++ b/src/locale/zh_CN/jquery.timeago.js @@ -0,0 +1,31 @@ +(function (factory) { + if (typeof define === 'function' && define.amd) { + define(['jquery'], factory); + } else if (typeof module === 'object' && typeof module.exports === 'object') { + factory(require('jquery')); + } else { + factory(jQuery); + } +}(function (jQuery) { + // Simplified Chinese + jQuery.timeago.settings.strings = { + prefixAgo: null, + prefixFromNow: "从现在开始", + suffixAgo: "之前", + suffixFromNow: null, + seconds: "不到1分钟", + minute: "大约1分钟", + minutes: "%d分钟", + hour: "大约1小时", + hours: "大约%d小时", + day: "1天", + days: "%d天", + month: "大约1个月", + months: "%d月", + year: "大约1年", + years: "%d年", + numbers: [], + wordSeparator: "" + }; +})); + diff --git a/src/policy.php b/src/policy.php new file mode 100644 index 0000000..f1f5ca1 --- /dev/null +++ b/src/policy.php @@ -0,0 +1,55 @@ +getSetting($mysqli, "name")); +define("TITLE", $db->getSetting($mysqli, "title")); +define("WEB_URL", $db->getSetting($mysqli, "url")); + +Template::render_header("Privacy Policy", "privacy"); + +echo "

            " . _("Privacy Policy") . "

            "; +echo "

            " . _("Who we are") . "

            "; +echo WHO_WE_ARE; +echo "

            " . _("Contact") . "

            "; +echo POLICY_NAME . "
            "; +echo ADDRESS . "
            "; +echo POLICY_MAIL . "
            "; +if (defined('POLICY_PHONE') && POLICY_PHONE != "") { + echo POLICY_PHONE . "
            "; +} + +echo '

            ' . _("What personal data we collect and why") . '

            '; +echo '

            ' . _("General") . "

            "; +echo _("If you access our websites, the following information will be saved: IP-address, Date, Time, Browser queries, + General information about your browser, operating system and all search queries on the sites. + This user data will be used for anonym user statistics to recognize trends and improve our content. + ") . "
            "; +echo '

            ' . _("Telegram") . "

            "; +echo _("If you use the Telegram Login Widget (The blue \"Login with Telegram\" button), we recive the following data from the service \"Telegram\" (telegram.org):"); +echo '
              +
            • ' . _("Your Telegram-User-ID") . "
            • +
            • " . _("Your Telegram username") . '
            • +
            • ' . _("The name you provided when registering with Telegram.") . '
            • +
            • ' . _("Your telegram profile picture") . '
            • +
            '; +echo _("Although we are receiving this data, we only save your telegram ID, your telegram username and the first and last name you provided telegram when registred for their service."); +echo _("We are saving this data, to provide a subscription service which alerts you about status update via our telegram bot. With this data we know who we need to send the alert to. Also we know your name, so we can say hi to you."); +echo _("Because of this, we also save who has subscribed which service."); +echo "

            " . _("How we protect your data") . "

            "; +echo _("In collaboration with our hosting provider we try our best to protect our + databases against access from third parties, losses, misuse or forgery. + ") . "

            "; +echo "

            " . _("Third party that receive your personal data") . "

            "; +echo "Our hosting provider can access the date we store on their server. We have a data processing agreement with them."; +echo "

            " . _("Cookies") . "

            "; +echo _("This site uses cookies – small text files that are placed on your machine to help the site provide a better user experience. + In general, cookies are used to retain user preferences, store information for things like shopping carts, + and provide anonymised tracking data to third party applications like Google Analytics. + As a rule, cookies will make your browsing experience better. However, you may prefer to disable cookies on this site and on others. + The most effective way to do this is to disable cookies in your browser. We suggest consulting the Help section of your browser + or taking a look at the About Cookies website which offers guidance for all modern browsers"); + +Template::render_footer(); diff --git a/robots.txt b/src/robots.txt similarity index 100% rename from robots.txt rename to src/robots.txt diff --git a/src/subscriptions.php b/src/subscriptions.php new file mode 100644 index 0000000..29e811a --- /dev/null +++ b/src/subscriptions.php @@ -0,0 +1,54 @@ +getSetting($mysqli, "name")); +define("TITLE", $db->getSetting($mysqli, "title")); +define("WEB_URL", $db->getSetting($mysqli, "url")); +define("MAILER_NAME", $db->getSetting($mysqli, "mailer")); +define("MAILER_ADDRESS", $db->getSetting($mysqli, "mailer_email")); +define("SUBSCRIBE_EMAIL", $db->getBooleanSetting($mysqli, "subscribe_email")); +define("SUBSCRIBE_TELEGRAM", $db->getBooleanSetting($mysqli, "subscribe_telegram")); +define("GOOGLE_RECAPTCHA", $db->getSetting($mysqli, "google_recaptcha")); +define("GOOGLE_RECAPTCHA_SECRET", $db->getSetting($mysqli, "google_recaptcha_secret")); +define("GOOGLE_RECAPTCHA_SITEKEY", $db->getSetting($mysqli, "google_recaptcha_sitekey")); +define("TG_BOT_API_TOKEN", $db->getSetting($mysqli, "tg_bot_api_token")); +define("TG_BOT_USERNAME", $db->getSetting($mysqli, "tg_bot_username")); + +$subscription = new Subscriptions(); +$telegram = new Telegram(); + +Template::render_header("Subscriptions", "subscripe"); + +if (SUBSCRIBE_TELEGRAM && $_SESSION['subscriber_typeid'] == 2) { + $tg_user = $telegram->getTelegramUserData(); // TODO: Do we need this any longer? +} + +if ($_SESSION['subscriber_valid']) { + $typeID = $_SESSION['subscriber_typeid']; + $subscriberID = $_SESSION['subscriber_id']; + $userID = $_SESSION['subscriber_userid']; + $token = $_SESSION['subscriber_token']; + + if (isset($_GET['add'])) { + $subscription->add($subscriberID, $_GET['add']); + } + + if (isset($_GET['remove'])) { + $subscription->remove($subscriberID, $_GET['remove']); + } + + $subscription->render_subscribed_services($typeID, $subscriberID, $userID, $token); +} else { + $header = _("Your session has expired or you tried something we don't suppprt"); + $message = _('If your session expired, retry your link or in case of Telegram use the login button in the top menu.'); + $constellation->render_warning($header, $message); + + header('Location: index.php'); +} + +Template::render_footer(); diff --git a/telegram_check.php b/src/telegram_check.php similarity index 58% rename from telegram_check.php rename to src/telegram_check.php index 595670f..9b87f7d 100644 --- a/telegram_check.php +++ b/src/telegram_check.php @@ -1,15 +1,14 @@ getSetting($mysqli,"name")); -define("TITLE", $db->getSetting($mysqli,"title")); -define("WEB_URL", $db->getSetting($mysqli,"url")); -define("MAILER_NAME", $db->getSetting($mysqli,"mailer")); -define("MAILER_ADDRESS", $db->getSetting($mysqli,"mailer_email")); -define("SUBSCRIBE_TELEGRAM", $db->getBooleanSetting($mysqli, "subscribe_telegram")); +define("NAME", $db->getSetting($mysqli, "name")); +define("TITLE", $db->getSetting($mysqli, "title")); +define("WEB_URL", $db->getSetting($mysqli, "url")); +define("MAILER_NAME", $db->getSetting($mysqli, "mailer")); +define("MAILER_ADDRESS", $db->getSetting($mysqli, "mailer_email")); define("SUBSCRIBE_TELEGRAM", $db->getBooleanSetting($mysqli, "subscribe_telegram")); define("TG_BOT_API_TOKEN", $db->getSetting($mysqli, "tg_bot_api_token")); define("TG_BOT_USERNAME", $db->getSetting($mysqli, "tg_bot_username")); @@ -18,10 +17,10 @@ $subscriber = new Subscriber(); try { - $auth_data = $telegram->checkTelegramAuthorization($_GET); - $telegram->saveTelegramUserData($auth_data); + $auth_data = $telegram->checkTelegramAuthorization($_GET); + $telegram->saveTelegramUserData($auth_data); } catch (Exception $e) { - die($e->getMessage()); + die($e->getMessage()); } // Check if user is registered in DB diff --git a/src/template.php b/src/template.php new file mode 100644 index 0000000..55e5f82 --- /dev/null +++ b/src/template.php @@ -0,0 +1,236 @@ +'; + // If subscriber is not logged on, display subscriber menus + if ((!isset($_SESSION['subscriber_valid'])) || false == $_SESSION['subscriber_valid']) { + $strSubsMenu .= '
          • '._('Subscriptions').'
          • '; - $strSubsMenu .= '
          • '._('Logout').'
          • '; - } - $strSubsMenu .= '
          '; - } - ?> - - - - - - <?php echo $page_name." - ".NAME ?> - - - - - - - - - - - - - - - - - - - - - - - - - - - -
          - - - - - - <?php echo $page_name." - ".NAME ?> - - - - - - - - - - - - - - - - - - - - - - - - -
          - -
          -

          - -
          - get_accepted_langs(); - ?> -
          -
          -
          -
          -
          Copyright © Server Status Project Contributors 1){ echo " and ".COPYRIGHT_TEXT; } ?>
          -
          -
          - - - -
          -
          -
          -
          -
          -
          - - - - - - - - - - - - - - + + PSR2 with two spaces + + + + + + + + + + + + + + + + + + + + \ No newline at end of file