Modified manager to new design

This commit is contained in:
Pax1601
2023-12-29 11:28:28 +01:00
parent 7450c9e506
commit 7391006a2f
38 changed files with 1779 additions and 1395 deletions

View File

@@ -0,0 +1,89 @@
<style>
#manager-connections .success,
#manager-connections .error {
position: absolute;
left: 420px;
display: flex;
width: 150px;
column-gap: 8px;
}
#manager-connections .success {
content: url("./icons/check-solid-green.svg");
height: 20px;
width: 20px;
}
#manager-connections .error img {
content: url("./icons/triangle-exclamation-solid.svg");
height: 20px;
width: 20px;
}
#manager-connections .error span {
font-weight: 600;
font-size: 12px;
color: var(--red);
height: fit-content;
}
</style>
<div id="manager-connections">
<div class="step-summary">
<div class="blue <%= !install? 'hide': '' %>">User path</div>
<div class="white">Ports and address</div>
<div class="empty">Passwords</div>
<div class="empty"> <%= install? 'Install': 'Update' %></div>
</div>
<div class="content">
<div class="instructions">
<span>
Accept or modify port settings (optional)
</span>
<span>
If you are installing Olympus locally for Single player use, it's recommended you leave these as default and continue.
If you are installing a dedicated server, then follow the instructions available on the DCS Olympus Wiki.
</span>
</div>
<div class="input-group client-port">
<span>Client port
<img src="./icons/circle-info-solid.svg" title="This port is used to allow access to Olympus. Be sure to allow this port through your firewall if you want people to connect remotely">
</span>
<div>
<input type="number" min="1024" max="65535" value="<%= instance["clientPort"] %>">
<img class="success hide">
<div class="error hide">
<img> <span>Port already in use</span>
</div>
</div>
</div>
<div class="input-group backend-port">
<span>Backend port
<img src="./icons/circle-info-solid.svg" title="This port is used to allow access to Olympus. Be sure to allow this port through your firewall if you want people to connect remotely.">
</span>
<div>
<input type="number" min="1024" max="65535" value="<%= instance["backendPort"] %>">
<img class="success hide">
<div class="error hide">
<img> <span>Port already in use</span>
</div>
</div>
</div>
<div class="input-group backend-address">
<span>Backend address
<img src="./icons/circle-info-solid.svg" title="This is the backend address Olympus will listen on. Unless you know what you are doing, leave it as localhost, even for dedicated server installations.">
</span>
<input type="text" value="<%= instance["backendAddress"] %>">
</div>
<div class="buttons-footer">
<div class="button back">
Back
</div>
<div class="button next">
Next
</div>
</div>
<div class="button cancel">
Cancel installation
</div>
</div>
</div>

View File

@@ -0,0 +1,112 @@
<style>
#manager-installations .scroll-container {
height: 100%;
overflow-y: auto;
}
#manager-installations .scrollable {
display: flex;
flex-direction: column;
row-gap: 8px;
height: fit-content;
align-items: center;
padding: 15px;
}
#manager-installations .option {
cursor: pointer;
background-color: var(--darkgray);
width: 600px;
height: 100px;
color: white;
display: flex;
font-size: 13px;
font-weight: 600;
padding-left: 15px;
align-items: center;
border-radius: 5px;
}
#manager-installations .option * {
pointer-events: none;
}
#manager-installations .option {
display: flex;
flex-direction: column;
row-gap: 5px;
align-items: start;
justify-content: center;
}
#manager-installations .option>span:nth-child(1) {
font-size: 18px;
font-weight: 600;
}
#manager-installations .option>span:nth-child(2) {
display: flex;
column-gap: 10px;
justify-content: center;
font-size: 13px;
font-weight: normal;
}
#manager-installations .option>span:nth-child(3) {
font-size: 13px;
font-weight: 600;
color: var(--lightgray);
}
#manager-installations .option>span:nth-child(3).installed {
font-weight: 600;
color: var(--green);
}
#manager-installations .option>span:nth-child(3).error {
font-weight: 600;
color: orange;
}
#manager-installations .option.installed {
pointer-events: none;
}
</style>
<div id="manager-installations">
<div class="step-summary">
<div class="white">User path</div>
<div class="empty">Ports and address</div>
<div class="empty">Passwords</div>
<div class="empty">Install</div>
</div>
<div class="content">
<div class="instructions">
<span>
Select a DCS path to install Olympus to.
</span>
<span>
We have automatically detected the following DCS installations under your Saved Games / DCS folder.
</span>
<span>
Please select which DCS installations you want to add Olympus to.
</span>
</div>
<div class="scroll-container">
<div class="scrollable">
<% for (let i = 0; i < instances.length; i++) {%>
<div class="option <%= instances[i].installed? 'installed': '' %>" data-folder="<%= instances[i].folder %>">
<span><%= instances[i].name %></span>
<span><img src="./icons/folder-open-solid.svg"> <%= instances[i].folder %></span>
<span class="<%= instances[i].installed? (instances[i].error? 'error': 'installed'): '' %>">
<%= instances[i].installed? (instances[i].error? 'Corrupted/outdated Olympus installation': 'Olympus already installed'): 'Olympus not installed yet' %>
</span>
</div>
<% } %>
</div>
</div>
<div class="button cancel">
Cancel installation
</div>
</div>
</div>

View File

@@ -1,68 +0,0 @@
<div class="instance-div">
<div class="folder-name">
<div class="icon folder"></div>
<span><%= folder %></span>
</div>
<div class="version">
Detected .dll version: <span class="<%= version === "n/a"? '' : (version === newVersion? 'accent-green': 'accent-red blink')%>"><%= version %></span> <br>
Available .dll version: <span class="accent-green"><%= newVersion %></span>
</div>
<div class="instance-content">
<table class="input-table">
<tr>
<td>
<div>
<div class="label">Client port <div class="icon info" title="This is the port that will allow users to connect to Olympus and must be forwarded in your firewall."></div></div>
<input id="client-port" type='number' value="<%= typeof client !== 'undefined' ? client["port"]: "" %>" min="1023" max="65535" <%= !installed? "disabled": "" %> tabindex="<%= index %>">
<span id="client-port-error" class="error"></span>
</div>
</td>
<td>
<div>
<div class="label">Game Master password <div class="icon info" title="This is the password you need to input to connect with the Game Master role."></div></div>
<input id="game-master-password" type="password" <%= !installed? "disabled": "" %> tabindex="<%= index + 3 %>">
<span id="game-master-password-error" class="error"></span>
</div>
</td>
</tr>
<tr>
<td>
<div>
<div class="label">Backend port <div class="icon info" title="This is the backend port used by Olympus to connect to DCS. You don't need to forward it in your firewall anymore."></div></div>
<input id="backend-port" type='number' value="<%= typeof server !== 'undefined' ? server["port"]: "" %>" min="1023" max="65535" <%= !installed? "disabled": "" %> tabindex="<%= index + 1 %>">
<span id="backend-port-error" class="error"></span>
</div>
</td>
<td>
<div>
<div class="label">Blue Commander password <div class="icon info" title="This is the password you need to input to connect with the Blue Commander role."></div></div>
<input id="blue-commander-password" type="password" <%= !installed? "disabled": "" %> tabindex="<%= index + 4 %>">
<span id="blue-commander-password-error" class="error"></span>
</div>
</td>
</tr>
<tr>
<td>
<div>
<div class="label">Backend address <div class="icon info" title="This is the address that DCS will listen on. Unless you want to send direct API commands, leave this to localhost even for dedicated server installations."></div></div>
<input id="backend-address" type='text' value="<%= typeof server !== 'undefined' ? server["address"]: "" %>" min="1023" max="65535" <%= !installed? "disabled": "" %> tabindex="<%= index + 2 %>">
<span id="backend-address-error" class="error"></span>
</div>
</td>
<td>
<div>
<div class="label">Red Commander password <div class="icon info" title="This is the password you need to input to connect with the Red Commander role."></div></div>
<input id="red-commander-password" type="password" <%= !installed? "disabled": "" %> tabindex="<%= index + 5 %>">
<span id="red-commander-password-error" class="error"></span>
</div>
</td>
</tr>
</table>
<div class="action-buttons">
<button class="button add <%= installed? "hide": "" %>" tabindex="<%= index + 6 %>" title="Clicking on this will install all the necessary files in your DCS instance. Remember to close DCS before doing this!">Install Olympus to instance</button>
<button class="button apply <%= !installed? "hide": "" %>" tabindex="<%= index + 7 %>" title="Clicking on this will apply your changes to the configuration. Remember to restart any running mission!">Apply changes</button>
<button class="button remove <%= !installed? "hide": "" %>" tabindex="<%= index + 8 %>" title="Clicking on this will remove Olympus from your DCS folder.">Remove Olympus</button>
<button class="button update <%= !(version !== "n/a" && version !== newVersion)? "hide": "" %>" tabindex="<%= index + 9 %>" title="Clicking on this will update Olympus in your DCS folder.">Update</button>
</div>
</div>
</div>

174
manager/ejs/instances.ejs Normal file
View File

@@ -0,0 +1,174 @@
<style>
#manager-instances {
padding-left: 80px;
padding-right: 80px;
}
#manager-instances .scroll-container {
height: 100%;
overflow-y: auto;
max-width: 100% !important;
width: 100%;
}
#manager-instances .scrollable {
display: flex;
row-gap: 15px;
column-gap: 15px;
height: fit-content;
width: 100%;
flex-wrap: wrap;
padding: 15px;
}
#manager-instances .option {
background-color: var(--darkgray);
width: 48%;
color: white;
display: flex;
font-size: 13px;
font-weight: 600;
padding: 15px;
align-items: center;
border-radius: 5px;
border-left: 5px solid var(--blue);
flex-direction: column;
row-gap: 25px;
}
#manager-instances>.instructions {
margin-bottom: 10px;
}
#manager-instances .button.cancel {
position: absolute;
left: 110px;
top: 180px;
}
#manager-instances .server-data {
display: flex;
column-gap: 15px;
row-gap: 5px;
flex-wrap: wrap;
}
#manager-instances .server-status {
font-weight: 600;
font-size: 15;
display: flex;
column-gap: 5px;
align-items: center;
}
#manager-instances .server-status::before {
display: block;
content: "";
width: 15px;
height: 15px;
border-radius: 999px;
background-color: var(--gray);
}
#manager-instances .server-status.offline {
color: var(--gray)
}
#manager-instances .server-status.offline::before {
background-color: var(--gray);
}
#manager-instances .server-status.online {
color: var(--green)
}
#manager-instances .server-status.online::before {
background-color: var(--green);
}
#manager-instances .server-status.backend {
margin-left: auto;
}
#manager-instances .server-data-entry {
display: flex;
column-gap: 5px;
align-items: center;
}
#manager-instances .server-data-entry span:nth-child(2) {
font-weight: 600;
}
#manager-instances .server-data-entry span:nth-child(3) {
font-weight: normal;
}
</style>
<div id="manager-instances">
<div class="content">
<div class="button cancel">
Return to menu
</div>
<div class="instructions">
<span>
<%= manage? "View and manage instances": "Update Olympus settings" %>
</span>
<span>
The following versions of Olympus have been detected.
</span>
<span>
<%= manage? "You can inspect and manage you Olympus instances by selecting the options below.": "You can edit your settings or remove Olympus by selecting the options below." %>
</span>
</div>
<div class="scroll-container">
<div class="scrollable">
<% for (let i = 0; i < instances.length; i++) {%>
<div class="option" data-folder="<%= instances[i].folder %>">
<div class="instance-info">
<span><%= instances[i].name %></span>
<span class="<%= instances[i].installed? (instances[i].error? 'error': ''): '' %>">
<%= instances[i].installed? (instances[i].error? 'Corrupted/outdated Olympus installation': ''): '' %>
</span>
<% if (!manage) { %>
<span><img src="./icons/folder-open-solid.svg"> <%= instances[i].folder %></span>
<% } else { %>
<div class="server-data">
<div class="server-status webserver online hide">ACTIVE</div>
<div class="server-status webserver offline">OFFLINE</div>
<div class="server-status backend online hide">CONNECTED</div>
<div class="server-status backend offline">DISCONNECTED</div>
<div class="server-data-entry fps"><img src="./icons/display-solid.svg"><span>FPS: </span><span class="data">0</span></div>
<div class="server-data-entry load"><img src="./icons/server-solid.svg"><span>Load: </span><span class="data">0</span></div>
<div class="server-data-entry uptime"></div>
</div>
<% } %>
<div class="divider"></div>
<div class="info">
<div>Client port</div>
<div> <%= instances[i].clientPort %> </div>
</div>
<div class="info">
<div>Backend port</div>
<div> <%= instances[i].backendPort %> </div>
</div>
<div class="info">
<div>Backend address</div>
<div> <%= instances[i].backendAddress %> </div>
</div>
</div>
<div class="instance-buttons">
<% if (!manage) { %>
<div class="button edit">Edit settings</div>
<div class="button uninstall">Uninstall</div>
<% } else { %>
<div class="button start-stop-server">Start server</div>
<!--<div class="button start-client">Start client</div>-->
<% } %>
</div>
</div>
<% } %>
</div>
</div>
</div>
</div>

View File

@@ -1,110 +0,0 @@
<style>
#manager-connections {
display: flex;
flex-direction: column;
row-gap: 15px;
}
#manager-connections .input-group {
color: var(--offwhite);
display: flex;
flex-direction: column;
row-gap: 5px;
}
#manager-connections .input-group>span:nth-child(1) {
font-size: 14px;
font-weight: 600;
}
#manager-connections .input-group>span:nth-child(2) {
font-size: 13px;
font-weight: normal;
}
#manager-connections .input-group div {
display: flex;
align-items: center;
column-gap: 5px;
flex-wrap: wrap;
}
#manager-connections>.instructions {
margin-bottom: 10px;
}
#manager-connections>.buttons-footer {
margin-top: 10px;
}
#manager-connections .client-port input {
width: 150px;
}
#manager-connections .backend-port input {
width: 150px;
}
#manager-connections .success {
content: url("./icons/check-solid-green.svg");
height: 20px;
width: 20px;
}
#manager-connections .error img {
content: url("./icons/triangle-exclamation-solid.svg");
height: 20px;
width: 20px;
}
#manager-connections .error span {
font-weight: 600;
font-size: 12px;
color: var(--red);
height: fit-content;
}
</style>
<div id="manager-connections">
<div class="page-header">
Step 2: Port and address settings
</div>
<div class="input-group client-port">
<span>Client port</span>
<span>This port is used to allow access to Olympus. Be sure to allow this port through your firewall if you want people to connect remotely.</span>
<div>
<input type="number" min="1024" max="65535" value="<%= instance["clientPort"] %>">
<img class="success hide">
<div class="error hide">
<img> <span>Port already in use</span>
</div>
</div>
</div>
<div class="input-group backend-port">
<span>Backend port</span>
<span>This port is used to communicate with DCS. It is not necessary to allow this port through your firewall.</span>
<div>
<input type="number" min="1024" max="65535" value="<%= instance["backendPort"] %>">
<img class="success hide">
<div class="error hide">
<img> <span>Port already in use</span>
</div>
</div>
</div>
<div class="input-group backend-address">
<span>Backend address</span>
<span>This is the backend address Olympus will listen on. Unless you know what you are doing, leave it as localhost, even for dedicated server installations.</span>
<input type="text" value="<%= instance["backendAddress"] %>">
</div>
<div class="buttons-footer">
<div class="button back">
Back
</div>
<div class="button next">
Next
</div>
<div class="button cancel">
Cancel
</div>
</div>
</div>

View File

@@ -1,134 +0,0 @@
<style>
#manager-installations .scroll-container {
height: 440px;
overflow-y: auto;
}
#manager-installations .scrollable {
display: flex;
flex-direction: column;
row-gap: 8px;
height: fit-content;
}
#manager-installations .scrollable>.option {
cursor: pointer;
background-color: var(--darkgray);
width: 100%;
height: 100px;
color: white;
display: flex;
font-size: 13px;
font-weight: 600;
padding-left: 15px;
align-items: center;
border-radius: 5px;
border-left: 5px solid var(--blue);
}
#manager-installations .scrollable>.option * {
pointer-events: none;
}
#manager-installations .scrollable>.option.selected {
background-color: var(--blue);
}
#manager-installations .scrollable>.option .checkbox {
padding-right: 20px;
content: url("./icons/square-regular.svg");
}
#manager-installations .scrollable>.option.selected .checkbox {
content: url("./icons/check-solid.svg");
}
#manager-installations .scrollable>.option>div {
display: flex;
flex-direction: column;
row-gap: 5px;
}
#manager-installations .scrollable>.option>div>span:nth-child(1) {
font-size: 18px;
font-weight: 600;
}
#manager-installations .scrollable>.option>div>span:nth-child(2) {
font-size: 13px;
font-weight: 600;
color: var(--gray);
}
#manager-installations .scrollable>.option>div>span:nth-child(2).installed {
font-weight: 600;
color: var(--green);
}
#manager-installations .scrollable>.option>div>span:nth-child(2).error {
font-weight: 600;
color: orange;
}
#manager-installations .scrollable>.option>div>span:nth-child(3) {
display: flex;
column-gap: 10px;
justify-content: center;
font-size: 13px;
font-weight: normal;
}
#manager-installations>.instructions {
margin-bottom: 10px;
}
#manager-installations>.buttons-footer {
margin-top: 10px;
}
</style>
<div id="manager-installations">
<div class="page-header">
Step 1: Select DCS Installations
</div>
<div class="instructions">
<span>
Select the copy of DCS you want to install Olympus to.
</span>
<span>
For most people, this is your main DCS installation.
</span>
<span>
If you are running a dedicated server, you would also install Olympus to this DCS version.
</span>
</div>
<div class="scroll-container">
<div class="scrollable">
<% for (let i = 0; i < instances.length; i++) {%>
<div class="option" data-folder="<%= instances[i].folder %>">
<img class="checkbox">
<div>
<span><%= instances[i].name %></span>
<span class="<%= instances[i].installed? (instances[i].error? 'error': 'installed'): '' %>">
<%= instances[i].installed? (instances[i].error? 'Corrupted/outdated Olympus installation': 'Olympus already installed'): 'Olympus not installed yet' %>
</span>
<span><img src="./icons/folder-open-solid.svg"> <%= instances[i].folder %></span>
</div>
</div>
<% } %>
</div>
</div>
<div class="buttons-footer">
<div class="button back">
Back
</div>
<div class="button next">
Next
</div>
<div class="button cancel">
Cancel
</div>
</div>
</div>

View File

@@ -1,153 +0,0 @@
<style>
#manager-instances .scroll-container {
height: 500px;
overflow-y: auto;
}
#manager-instances .scrollable {
display: flex;
flex-direction: column;
row-gap: 8px;
height: fit-content;
}
#manager-instances .scrollable>.option {
cursor: pointer;
background-color: var(--darkgray);
width: 100%;
height: 230px;
color: white;
display: flex;
font-size: 13px;
font-weight: 600;
padding-left: 15px;
align-items: center;
border-radius: 5px;
border-left: 5px solid var(--blue);
}
#manager-instances .scrollable>.option * {
pointer-events: none;
}
#manager-instances .scrollable>.option.selected {
background-color: var(--blue);
}
#manager-instances .scrollable>.option .checkbox {
padding-right: 20px;
content: url("./icons/square-regular.svg");
}
#manager-instances .scrollable>.option.selected .checkbox {
content: url("./icons/check-solid.svg");
}
#manager-instances .scrollable>.option>div {
display: flex;
flex-direction: column;
row-gap: 5px;
}
#manager-instances .scrollable>.option>div>span:nth-child(1) {
font-size: 18px;
font-weight: 600;
}
#manager-instances .scrollable>.option>div>span:nth-child(2) {
font-size: 13px;
font-weight: 600;
color: var(--gray);
}
#manager-instances .scrollable>.option>div>span:nth-child(2).installed {
font-weight: 600;
color: var(--green);
}
#manager-instances .scrollable>.option>div>span:nth-child(2).error {
font-weight: 600;
color: orange;
}
#manager-instances .scrollable>.option>div>span:nth-child(3) {
display: flex;
column-gap: 10px;
justify-content: center;
font-size: 13px;
font-weight: normal;
}
#manager-instances>.instructions {
margin-bottom: 10px;
}
#manager-instances>.buttons-footer {
margin-top: 10px;
}
#manager-instances .info {
display: flex;
flex-direction: column;
row-gap: 5px;
}
#manager-instances .info>div:nth-child(1) {
font-weight: 600;
font-size: 14px;
}
#manager-instances .info>div:nth-child(2) {
font-weight: normal;
font-size: 14px;
}
</style>
<div id="manager-instances">
<div class="page-header">
Step 1: Select Olympus Installations
</div>
<div class="instructions">
<span>
Select the copy of Olympus you want to manage.
</span>
</div>
<div class="scroll-container">
<div class="scrollable">
<% for (let i = 0; i < instances.length; i++) {%>
<div class="option" data-folder="<%= instances[i].folder %>">
<div>
<span><%= instances[i].name %></span>
<span class="<%= instances[i].installed? (instances[i].error? 'error': ''): '' %>">
<%= instances[i].installed? (instances[i].error? 'Corrupted/outdated Olympus installation': ''): '' %>
</span>
<span><img src="./icons/folder-open-solid.svg"> <%= instances[i].folder %></span>
<div class="info">
<div>Client port</div>
<div> <%= instances[i].clientPort %> </div>
</div>
<div class="info">
<div>Backend port</div>
<div> <%= instances[i].backendPort %> </div>
</div>
<div class="info">
<div>Backend address</div>
<div> <%= instances[i].backendAddress %> </div>
</div>
</div>
</div>
<% } %>
</div>
</div>
<div class="buttons-footer">
<div class="button back">
Back
</div>
<div class="button next">
Next
</div>
<div class="button cancel">
Cancel
</div>
</div>
</div>

View File

@@ -1,45 +0,0 @@
<style>
#manager-menu {
display: flex;
flex-direction: column;
row-gap: 8px;
}
#manager-menu>.option {
background-color: var(--blue);
width: 100%;
height: 50px;
color: white;
display: flex;
font-size: 13px;
font-weight: 600;
padding-left: 15px;
align-items: center;
border-radius: 5px;
cursor: pointer;
}
#manager-menu>.option * {
pointer-events: none;
}
.inverted {
background-color: var(--gray) !important;
color: var(--background) !important;
}
</style>
<div id="manager-menu">
<div class="page-header">
What do you want to do?
</div>
<div class="option install">
Install Olympus
</div>
<div class="option update">
Update/remove Olympus
</div>
<div class="option inverted manage">
View and manage instances (WIP)
</div>
</div>

View File

@@ -1,73 +0,0 @@
<style>
#manager-passwords {
display: flex;
flex-direction: column;
row-gap: 15px;
}
#manager-passwords .input-group {
color: var(--offwhite);
display: flex;
flex-direction: column;
row-gap: 5px;
}
#manager-passwords .input-group>span:nth-child(1) {
font-size: 14px;
font-weight: 600;
}
#manager-passwords .input-group>span:nth-child(2) {
font-size: 13px;
font-weight: normal;
}
#manager-passwords>.instructions {
margin-bottom: 10px;
}
#manager-passwords>.buttons-footer {
margin-top: 10px;
}
#manager-passwords input {
width: 250px;
}
</style>
<div id="manager-passwords">
<div class="page-header">
Step 3: Passwords
</div>
<div class="input-group">
<span>Enter your passwords to access Olympus</span>
<span>By using the passwords below, you can access different roles in Olympus.</span>
</div>
<div class="input-group game-master">
<span>Game Master Password</span>
<span>This password is used to access Olympus as Game Master with full priviledges.</span>
<input type="password" minlength="8">
</div>
<div class="input-group blue-commander">
<span>Blue Commander Password</span>
<span>This password is used to access Olympus as blue coalition Commander.</span>
<input type="password" minlength="8">
</div>
<div class="input-group red-commander">
<span>Red Commander Password</span>
<span>This password is used to access Olympus as red coalition Commander.</span>
<input type="password" minlength="8">
</div>
<div class="buttons-footer">
<div class="button back">
Back
</div>
<div class="button next">
Next
</div>
<div class="button cancel">
Cancel
</div>
</div>
</div>

View File

@@ -1,160 +0,0 @@
<style>
#manager-result {
display: flex;
flex-direction: column;
row-gap: 15px;
}
#manager-result img.success {
content: url("./icons/check-solid-green.svg");
height: 20px;
width: 20px;
}
#manager-result img.error {
content: url("./icons/triangle-exclamation-solid.svg");
height: 20px;
width: 20px;
}
#manager-result img.wait {
content: url("./icons/spinner-solid.svg");
height: 20px;
width: 20px;
animation: rotate 2s linear infinite;
}
@keyframes rotate {
0% {
transform: rotate(0deg)
}
100% {
transform: rotate(360deg)
}
}
#manager-result .summary {
font-weight: 600;
font-size: 14px;
}
#manager-result .summary.success {
color: var(--green);
}
#manager-result .summary.error {
color: var(--red);
}
#manager-result .info {
font-weight: 600;
font-size: 14px;
color: var(--offwhite);
}
.step {
display: flex;
align-items: center;
font-size: 13px;
font-weight: 600;
color: var(--offwhite);
column-gap: 10px;
}
#manager-result>.result {
cursor: pointer;
background-color: var(--blue);
width: 100%;
height: 80px;
color: white;
display: flex;
font-size: 13px;
font-weight: 600;
padding-left: 15px;
align-items: center;
border-radius: 5px;
}
#manager-result>.result>img {
margin-left: 5px;
margin-right: 20px;
}
#manager-result>.result>div {
display: flex;
flex-direction: column;
row-gap: 5px;
}
#manager-result>.result>div>span:nth-child(1) {
font-size: 15px;
font-weight: 600;
}
#manager-result>.result>div>span:nth-child(2) {
display: flex;
column-gap: 10px;
justify-content: center;
font-size: 13px;
font-weight: normal;
}
</style>
<div id="manager-result">
<div class="page-header">
Please wait while Olympus is being installed
</div>
<div class="step hook">
Installing hook scripts<img class="wait"><img class="success hide"><img class="error hide">
</div>
<div class="step mod">
Installing mod folder<img class="wait"><img class="success hide"><img class="error hide">
</div>
<div class="step json">
Installing configuration file<img class="wait"><img class="success hide"><img class="error hide">
</div>
<div class="step config">
Applying configuration<img class="wait"><img class="success hide"><img class="error hide">
</div>
<div class="step shortcuts">
Creating shortcuts<img class="wait"><img class="success hide"><img class="error hide">
</div>
<div class="summary success hide">
Olympus successfully installed in the following DCS instance
</div>
<div class="summary error hide">
An error has occurred while installing Olympus
</div>
<div class="result">
<img class="wait"><img class="success hide"><img class="error hide">
<div>
<span>
<%= instance.name %>
</span>
<span><img src="./icons/folder-open-solid.svg">
<%= instance.folder %>
</span>
</div>
</div>
<div class="info success">
You may now start DCS and use Olympus either with the shortcuts or the "View and manage Olympus" entry in the
main menu
</div>
<div class="info error">
Please make sure DCS is not currently being executed
</div>
<div class="buttons-footer">
<div class="button back">
Back to main menu
</div>
<!--<div class="button cancel">
Close
</div>-->
</div>
</div>

88
manager/ejs/menu.ejs Normal file
View File

@@ -0,0 +1,88 @@
<style>
#summary {
width: 70%;
display: flex;
flex-direction: column;
height: 100%;
justify-content: center;
color: var(--offwhite);
padding: 80px;
}
#summary .icon {
height: 100px;
width: 100px;
margin-bottom: -30px;
}
#summary div:nth-child(1) {
font-size: 50px;
font-weight: bold;
}
#summary div:nth-child(2) {
font-size: 20px;
font-weight: bold;
}
#summary div:nth-child(3) {
color: var(--lightgray);
font-size: 13px;
font-weight: normal;
margin-top: 20px;
width: 300px;
}
#manager-menu #menu {
display: flex;
flex-direction: column;
row-gap: 20px;
width: 60%;
justify-content: center;
align-items: center;
}
#manager-menu .option {
background-color: var(--background);
border: 1px solid var(--offwhite);
width: 460px;
height: 80px;
color: var(--offwhite);
display: flex;
font-size: 20px;
font-weight: 600;
padding-left: 15px;
align-items: center;
border-radius: 5px;
cursor: pointer;
}
#manager-menu .option:hover {
color: var(--background);
background-color: var(--offwhite);
}
#manager-menu .option * {
pointer-events: none;
}
</style>
<div id="manager-menu">
<div id="summary">
<div>DCS OLYMPUS <img class="icon" src="../img/OlympusLogoFinal_4k.png" \></div>
<div>INSTALL WIZARD AND MANAGER</div>
<div>Using this manager, you can install Olympus, update settings, and view and manage instances</div>
</div>
<div id="menu">
<div class="option install">
Install Olympus
</div>
<div class="option update">
Update/remove Olympus
</div>
<div class="option divider"></div>
<div class="option manage">
View and manage instances
</div>
</div>
</div>

48
manager/ejs/passwords.ejs Normal file
View File

@@ -0,0 +1,48 @@
<style>
</style>
<div id="manager-passwords">
<div class="step-summary">
<div class="blue <%= !install? 'hide': '' %>">User path</div>
<div class="blue">Ports and address</div>
<div class="white">Passwords</div>
<div class="empty"> <%= install? 'Install': 'Update' %></div>
</div>
<div class="content">
<div class="instructions">
<span>
Enter your passwords to access Olympus
</span>
<span>
When logging into Olympus, these passwords will let you access the different roles. Gamemaster is the default.
</span>
</div>
<div class="input-group game-master">
<span>Game Master Password<img src="./icons/circle-info-solid.svg" title="This password is used to access Olympus as Game Master with full privileges.">
</span>
<input type="password" minlength="8">
</div>
<div class="input-group blue-commander">
<span>Blue Commander Password<img src="./icons/circle-info-solid.svg" title="This password is used to access Olympus as blue coalition Commander.">
</span>
<input type="password" minlength="8">
</div>
<div class="input-group red-commander">
<span>Red Commander Password<img src="./icons/circle-info-solid.svg" title="This password is used to access Olympus as red coalition Commander.">
</span>
<input type="password" minlength="8">
</div>
<div class="buttons-footer">
<div class="button back">
Back
</div>
<div class="button next">
Next
</div>
</div>
<div class="button cancel">
Cancel installation
</div>
</div>
</div>

View File

@@ -1,10 +0,0 @@
<div class="popup-header">
Information
</div>
<div class="popup-content">
<%= message %>
</div>
<div class="popup-footer">
<button class="button other <%= otherButton? "": " hide"%>" ><%= otherButton %></button>
<button class="button apply">Close</button>
</div>

146
manager/ejs/result.ejs Normal file
View File

@@ -0,0 +1,146 @@
<style>
#manager-result .content {
width: 100% !important;
}
#manager-result img.success {
content: url("./icons/check-solid-green.svg");
height: 20px;
width: 20px;
}
#manager-result img.error {
content: url("./icons/triangle-exclamation-solid.svg");
height: 20px;
width: 20px;
}
#manager-result img.wait {
content: url("./icons/spinner-solid.svg");
height: 20px;
width: 20px;
animation: rotate 2s linear infinite;
}
#manager-result .summary {
font-weight: 600;
font-size: 24px;
}
#manager-result .summary.success {
color: var(--green);
}
#manager-result .summary.error {
color: var(--red);
}
#manager-result .info {
font-weight: 600;
font-size: 14px;
color: var(--offwhite);
}
#manager-result .step {
display: flex;
align-items: center;
font-size: 13px;
font-weight: 600;
color: var(--offwhite);
column-gap: 10px;
}
#manager-result .result {
cursor: pointer;
background-color: var(--darkgray);
border-left: 5px solid var(--blue);
width: 100%;
height: 80px;
color: white;
display: flex;
font-size: 13px;
font-weight: 600;
padding-left: 15px;
align-items: center;
border-radius: 5px;
width: 500px;
}
#manager-result .result>img {
margin-left: 5px;
margin-right: 20px;
}
#manager-result .result>div {
display: flex;
flex-direction: column;
row-gap: 5px;
}
#manager-result .result>div>span:nth-child(1) {
font-size: 15px;
font-weight: 600;
}
#manager-result .result>div>span:nth-child(2) {
display: flex;
column-gap: 10px;
justify-content: center;
font-size: 13px;
font-weight: normal;
}
</style>
<div id="manager-result">
<div class="content">
<div class="step hook <%= !install? 'hide': '' %>">
Installing hook scripts<img class="wait"><img class="success hide"><img class="error hide">
</div>
<div class="step mod <%= !install? 'hide': '' %>">
Installing mod folder<img class="wait"><img class="success hide"><img class="error hide">
</div>
<div class="step json <%= !install? 'hide': '' %>">
Installing configuration file<img class="wait"><img class="success hide"><img class="error hide">
</div>
<div class="step config">
Applying configuration<img class="wait"><img class="success hide"><img class="error hide">
</div>
<div class="step shortcuts <%= !install? 'hide': '' %>">
Creating shortcuts<img class="wait"><img class="success hide"><img class="error hide">
</div>
<div class="summary success hide">
Olympus successfully installed in the following DCS instance
</div>
<div class="summary error hide">
An error has occurred while installing Olympus
</div>
<div class="info success hide">
You may now start DCS and use Olympus either with the shortcuts or the "View and manage instances" entry in the
main menu
</div>
<div class="info error hide">
Please make sure DCS is not currently being executed
</div>
<div class="result">
<img class="wait"><img class="success hide"><img class="error hide">
<div>
<span>
<%= instance.name %>
</span>
<span><img src="./icons/folder-open-solid.svg">
<%= instance.folder %>
</span>
</div>
</div>
<div class="buttons-footer">
<div class="button back">
Back to main menu
</div>
</div>
</div>
</div>