Compare commits

..

24 Commits

Author SHA1 Message Date
Agampreet Singh
f82837ac4f Update README.md 2023-06-12 23:54:50 +05:30
Agampreet Singh
6c1edd0a98 Do not include assets/icons in extraFiles 2023-06-12 19:41:25 +05:30
Agampreet Singh
72516bd2fd Add a "Copy URL" button in menu 2023-06-12 15:15:33 +05:30
Agampreet Singh
38a4db3538 Rearrange menu 2023-06-12 15:01:02 +05:30
Agampreet Singh
aab2397043 Use a better way to check menu item 2023-06-12 13:27:49 +05:30
Agampreet Singh
034e2f36c3 Shorten menu label/description 2023-06-12 13:27:41 +05:30
Agampreet Singh
b44ee69787 Make the menu feel more native 2023-06-12 12:42:59 +05:30
Agampreet Singh
0ba2721ea3 Add option to enable/disable auto updater 2023-06-12 00:49:47 +05:30
Agampreet Singh
d2ed102ccc Rearrange MS-365-Electron menu 2023-06-12 00:35:08 +05:30
Agampreet Singh
dd8110479b Add accelerator for Back, Forward and Reload buttons 2023-06-11 23:24:54 +05:30
Agampreet Singh
848e93ae09 Let user enable/disable "Dynamic Icons"
- Auto Icon Changer will be called "Dynamic Icons" from now on
2023-06-11 23:20:17 +05:30
Agampreet Singh
1625a46529 Only keep "Block Ads and Trackers" option 2023-06-11 22:50:00 +05:30
Agampreet Singh
1526a81d1c Update user-agent strings 2023-06-11 21:54:56 +05:30
Agampreet Singh
5b4db16b64 Do not log if internet is connected 2023-06-11 21:49:09 +05:30
Agampreet Singh
0e02c64999 Cleanup the main file 2023-06-11 21:48:03 +05:30
Agampreet Singh
9d2b63fedb Move everything related to store in store.js 2023-06-11 21:15:36 +05:30
Agampreet Singh
15d339d7f9 Add OneDrive option under Apps menu 2023-06-11 21:00:59 +05:30
Agampreet Singh
ec12b02d7e Add "Apps" menu 2023-06-11 21:00:49 +05:30
Agampreet Singh
e003c64444 Update LICENSE 2023-06-11 18:17:38 +05:30
Agampreet Singh
e680f8eb37 Welcome back about-window! 2023-06-11 18:16:30 +05:30
Agampreet Singh
1e1828b3f2 Rename menu label 2023-06-11 17:49:27 +05:30
Agampreet Singh
a9d63d7325 Use rpcError function for all RPC related errors
- Also add "Disable Discord RPC" button to the error message
2023-06-11 17:48:30 +05:30
Agampreet Singh
95e14db4f8 Only change icons if some window is focused
- This commit fixes the error shown if no window is focused
2023-06-11 17:39:53 +05:30
Agampreet Singh
6a294dadd0 Use URL to check which website is opened 2023-06-11 17:39:02 +05:30
33 changed files with 1707 additions and 324 deletions

Binary file not shown.

View File

@@ -1,6 +1,7 @@
MIT License
Copyright (c) 2021-2023 Agampreet Singh
Microsoft 365, the name, website, images/icons are the intellectual properties of Microsoft.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

View File

@@ -72,6 +72,13 @@ Supported Platforms
# List of Features
- Discord RPC
- Dynamic Icons:
- For macOS: Change icon in dock according to the app you've opened [[Preview]](https://github-production-user-asset-6210df.s3.amazonaws.com/68941022/245203309-3d0dfc1b-02e9-43a8-85d7-9493a2b86b56.mp4)
- For Windows: Set overlay icon [[Preview]](https://github.com/agam778/MS-365-Electron/assets/68941022/791b661b-2b7d-43a6-96df-ee9c30c9b18a)
- For Linux: Nothing, yet
- Block Ads within the app
- Directly open apps from the menu
- Ability to use useragent strings of Windows, macOS or Linux
- Switch between normal and enterprise/education/developer account in the same app
- Back, Forward, Reload, and Home buttons
@@ -105,6 +112,13 @@ For Installing this app on Mac :-
2. Scroll down and click the `.dmg` file (according to your system architecture).
3. After it downloads, click on the file and mount it on your system. Now drag my app to the Applications Folder (There will be a shortcut in the opened window too) and your app will be installed. Open from Launchpad and enjoy.
## 📸 macOS Preview
<details>
<summary>Click to expand</summary>
<img src="https://github.com/agam778/MS-365-Electron/assets/68941022/fcc24409-7e4b-4802-9f3f-a7c420c0edcb" alt="macOS Preview">
</details>
# Linux
## 💿 Installation on Linux
@@ -159,10 +173,6 @@ For Installing in Red Hat/Fedora based distribution :-
sudo emerge -a ms-office-electron
```
## 📸 Ubuntu Preview
[Click Here](https://github.com/agam778/MS-365-Electron/blob/main/assets/screenshots/ubuntu.png?raw=true)
# 💻 Developing Locally
To build the app locally:<br>
Run the following commands to clone the repository and install the dependencies

344
app/main.js Normal file
View File

@@ -0,0 +1,344 @@
const { app, Menu, BrowserWindow, dialog, nativeImage } = require("electron");
const { autoUpdater } = require("electron-updater");
const checkInternetConnected = require("check-internet-connected");
const ElectronDl = require("electron-dl");
const contextMenu = require("electron-context-menu");
const path = require("path");
const log = require("electron-log");
const { setActivity, loginToRPC, clearActivity } = require("./rpc");
const useragents = require("./useragents.json");
const { ElectronBlocker } = require("@cliqz/adblocker-electron");
const { getValue } = require("./store");
const { menulayout } = require("./menu");
log.transports.file.level = "verbose";
console.log = log.log;
Object.assign(console, log.functions);
function createWindow() {
const win = new BrowserWindow({
width: 1181,
height: 670,
icon: path.join(__dirname, "/assets/icons/png/1024x1024.png"),
show: false,
webPreferences: {
nodeIntegration: true,
devTools: true,
},
});
if (getValue("autohide-menubar") === "true") {
win.setAutoHideMenuBar(true);
} else {
win.setAutoHideMenuBar(false);
}
const splash = new BrowserWindow({
width: 810,
height: 610,
transparent: true,
frame: false,
alwaysOnTop: true,
icon: path.join(__dirname, "/assets/icons/png/1024x1024.png"),
});
splash.loadURL(`https://agam778.github.io/MS-365-Electron/loading`);
win.loadURL(
`${getValue("enterprise-or-normal") || "https://microsoft365.com/?auth=1"}`,
{
userAgent: getValue("useragentstring") || useragents.Windows,
}
);
win.webContents.on("did-finish-load", () => {
splash.destroy();
win.show();
if (getValue("discordrpcstatus") === "true") {
setActivity(`On "${win.webContents.getTitle()}"`);
}
if (getValue("blockadsandtrackers") === "true") {
ElectronBlocker.fromPrebuiltAdsAndTracking(fetch).then((blocker) => {
blocker.enableBlockingInSession(win.webContents.session);
});
}
});
}
ElectronDl({
dlPath: "./downloads",
onStarted: (item) => {
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(
__dirname + "/assets/icons/download.png",
"Downloading"
);
});
dialog.showMessageBox({
type: "info",
title: "Downloading File",
message: `Downloading "${item.getFilename()}" to "${item.getSavePath()}"`,
buttons: ["OK"],
});
},
onCompleted: () => {
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(
__dirname + "/assets/icons/download-success.png",
"Download Successful"
);
});
dialog.showMessageBox({
type: "info",
title: "Download Completed",
message: `Downloading Completed! Please check your "Downloads" folder.`,
buttons: ["OK"],
});
setTimeout(() => {
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(null, "");
});
}, 7000);
},
onError: (item) => {
dialog.showMessageBox({
type: "error",
title: "Download failed",
message: `Downloading "${item.getFilename()}" failed :(`,
buttons: ["OK"],
});
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(
__dirname + "/download-fail.png",
"Download Failed"
);
});
setTimeout(() => {
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(null, "");
});
}, 7000);
},
});
contextMenu({
showInspectElement: false,
showServices: false,
});
Menu.setApplicationMenu(Menu.buildFromTemplate(menulayout));
app.on("ready", () => {
createWindow();
});
app.on("web-contents-created", (event, contents) => {
contents.setWindowOpenHandler(({ url }) => {
if (getValue("websites-in-new-window") === "false") {
if (url.includes("page=Download")) {
return { action: "allow" };
} else {
BrowserWindow.getFocusedWindow().loadURL(url);
if (getValue("discordrpcstatus") === "true") {
setActivity(
`On "${BrowserWindow.getFocusedWindow().webContents.getTitle()}"`
);
}
return { action: "deny" };
}
} else {
if (getValue("discordrpcstatus") === "true") {
setActivity(
`On "${BrowserWindow.getFocusedWindow().webContents.getTitle()}"`
);
}
return { action: "allow" };
}
});
contents.on("did-finish-load", () => {
if (getValue("dynamicicons") === "true") {
if (BrowserWindow.getFocusedWindow()) {
if (
BrowserWindow.getFocusedWindow()
.webContents.getURL()
.includes("&ithint=file%2cpptx")
) {
if (process.platform === "darwin") {
app.dock.setIcon(
path.join(__dirname, "../assets/icons/apps/powerpoint-mac.png")
);
} else if (process.platform === "win32") {
let nimage = nativeImage.createFromPath(
path.join(__dirname, "../assets/icons/apps/powerpoint.png")
);
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(nimage, "PowerPoint");
});
}
} else if (
BrowserWindow.getFocusedWindow()
.webContents.getURL()
.includes("&ithint=file%2cdocx")
) {
if (process.platform === "darwin") {
app.dock.setIcon(
path.join(__dirname, "../assets/icons/apps/word-mac.png")
);
} else if (process.platform === "win32") {
let nimage = nativeImage.createFromPath(
path.join(__dirname, "../assets/icons/apps/word.png")
);
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(nimage, "Word");
});
}
} else if (
BrowserWindow.getFocusedWindow()
.webContents.getURL()
.includes("&ithint=file%2cxlsx")
) {
if (process.platform === "darwin") {
app.dock.setIcon(
path.join(__dirname, "../assets/icons/apps/excel-mac.png")
);
} else if (process.platform === "win32") {
let nimage = nativeImage.createFromPath(
path.join(__dirname, "../assets/icons/apps/excel.png")
);
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(nimage, "Excel");
});
}
} else if (
BrowserWindow.getFocusedWindow()
.webContents.getURL()
.includes("outlook.live.com")
) {
if (process.platform === "darwin") {
app.dock.setIcon(
path.join(__dirname, "../assets/icons/apps/outlook-mac.png")
);
} else if (process.platform === "win32") {
let nimage = nativeImage.createFromPath(
path.join(__dirname, "../assets/icons/apps/outlook.png")
);
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(nimage, "Outlook");
});
}
} else if (
BrowserWindow.getFocusedWindow()
.webContents.getURL()
.includes("onedrive.live.com")
) {
if (process.platform === "darwin") {
app.dock.setIcon(
path.join(__dirname, "../assets/icons/apps/onedrive-mac.png")
);
} else if (process.platform === "win32") {
let nimage = nativeImage.createFromPath(
path.join(__dirname, "../assets/icons/apps/onedrive.png")
);
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(nimage, "OneDrive");
});
}
} else if (
BrowserWindow.getFocusedWindow()
.webContents.getURL()
.includes("teams.live.com")
) {
if (process.platform === "darwin") {
app.dock.setIcon(
path.join(__dirname, "../assets/icons/apps/teams-mac.png")
);
} else if (process.platform === "win32") {
let nimage = nativeImage.createFromPath(
path.join(__dirname, "../assets/icons/apps/teams.png")
);
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(nimage, "Teams");
});
}
} else if (
BrowserWindow.getFocusedWindow()
.webContents.getURL()
.includes("&ithint=onenote")
) {
if (process.platform === "darwin") {
app.dock.setIcon(
path.join(__dirname, "../assets/icons/apps/onenote-mac.png")
);
} else if (process.platform === "win32") {
let nimage = nativeImage.createFromPath(
path.join(__dirname, "../assets/icons/apps/onenote.png")
);
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(nimage, "OneNote");
});
}
} else {
if (process.platform === "darwin") {
app.dock.setIcon(null);
} else {
BrowserWindow.getAllWindows().forEach((window) => {
window.setOverlayIcon(null, "");
});
}
}
}
}
});
});
app.on("browser-window-created", (event, window) => {
window.webContents.on("did-finish-load", () => {
if (getValue("discordrpcstatus") === "true") {
setActivity(`On "${window.webContents.getTitle()}"`);
}
});
if (getValue("blockadsandtrackers") === "true") {
ElectronBlocker.fromPrebuiltAdsAndTracking(fetch).then((blocker) => {
blocker.enableBlockingInSession(window.webContents.session);
});
}
});
app.on("window-all-closed", () => {
if (process.platform !== "darwin") {
app.quit();
}
if (process.platform === "darwin") {
app.dock.setIcon(null);
}
clearActivity();
});
app.on("activate", () => {
if (BrowserWindow.getAllWindows().length === 0) {
createWindow();
}
});
app.on("ready", function () {
checkInternetConnected().catch(() => {
const options = {
type: "warning",
buttons: ["Ok"],
defaultId: 2,
title: "Warning",
message: "You appear to be offline!",
detail:
"Please check your Internet Connectivity. This app cannot run without an Internet Connection!",
};
dialog.showMessageBox(null, options, (response) => {
console.log(response);
});
});
if (getValue("autoupdater") === "true") {
autoUpdater.checkForUpdatesAndNotify();
}
if (getValue("discordrpcstatus") === "true") {
loginToRPC();
setActivity(`Opening Microsoft 365...`);
}
});

File diff suppressed because it is too large Load Diff

View File

@@ -1,18 +1,28 @@
const { Client } = require("@xhayper/discord-rpc");
const { dialog, BrowserWindow } = require("electron");
const { setValue } = require("./store");
const client = new Client({
clientId: "942637872530460742",
});
async function rpcError(status) {
const rpcerror = dialog.showMessageBoxSync(BrowserWindow.getFocusedWindow(), {
type: "error",
title: "Discord RPC Error",
message: `Oops! An Error occured while ${status} Discord RPC.`,
buttons: ["Close", "Disable Discord RPC"],
});
if (rpcerror === 1) {
setValue("discordrpcstatus", "false");
}
}
async function clearActivity() {
await client.user?.clearActivity().catch((err) => {
dialog.showMessageBox(BrowserWindow.getFocusedWindow(), {
type: "error",
title: "Discord RPC Error",
message: "Oops! An Error occured while clearing Discord RPC.",
buttons: ["OK"],
});
rpcError("clearing");
console.error(err);
});
}
@@ -28,24 +38,14 @@ async function setActivity(details) {
largeImageText: "MS-365-Electron",
})
.catch((err) => {
dialog.showMessageBox(BrowserWindow.getFocusedWindow(), {
type: "error",
title: "Discord RPC Error",
message: "Oops! An Error occured while setting Discord RPC.",
buttons: ["OK"],
});
rpcError("setting");
console.error(err);
});
}
async function loginToRPC() {
await client.login().catch((err) => {
dialog.showMessageBox(BrowserWindow.getFocusedWindow(), {
type: "error",
title: "Discord RPC Error",
message: "Oops! An Error occured while connecting to Discord RPC.",
buttons: ["OK"],
});
rpcError("logging into");
console.error(err);
});
}

View File

@@ -1,4 +1,21 @@
const Store = require("electron-store");
const store = new Store();
module.exports = store;
function getValue(key) {
return store.get(key);
}
function setValue(key, value) {
store.set(key, value);
}
function getValueOrDefault(key, defaultValue) {
const value = store.get(key);
if (value === undefined) {
store.set(key, defaultValue);
return defaultValue;
}
return value;
}
module.exports = { getValue, setValue, getValueOrDefault };

View File

@@ -1,5 +1,5 @@
{
"Windows": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36",
"macOS": "Mozilla/5.0 (Macintosh; Intel Mac OS X 13_2_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36",
"Linux": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36"
"Windows": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36",
"macOS": "Mozilla/5.0 (Macintosh; Intel Mac OS X 13_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36",
"Linux": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36"
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 214 KiB

After

Width:  |  Height:  |  Size: 228 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 159 KiB

After

Width:  |  Height:  |  Size: 207 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

After

Width:  |  Height:  |  Size: 37 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 156 KiB

After

Width:  |  Height:  |  Size: 208 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 156 KiB

After

Width:  |  Height:  |  Size: 203 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 172 KiB

After

Width:  |  Height:  |  Size: 218 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 53 KiB

After

Width:  |  Height:  |  Size: 57 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 158 KiB

After

Width:  |  Height:  |  Size: 210 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

After

Width:  |  Height:  |  Size: 52 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 161 KiB

After

Width:  |  Height:  |  Size: 215 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

After

Width:  |  Height:  |  Size: 41 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 159 KiB

After

Width:  |  Height:  |  Size: 208 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 83 KiB

After

Width:  |  Height:  |  Size: 89 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

View File

@@ -1 +1,45 @@
<svg xmlns="http://www.w3.org/2000/svg" width="1365.333" height="1365.333" preserveAspectRatio="xMidYMid meet" version="1.0" viewBox="0 0 1024 1024"><metadata>Created by potrace 1.14, written by Peter Selinger 2001-2017</metadata><g fill="#000" stroke="none"><path d="M4958 9915 c-2 -2 -32 -6 -67 -9 -35 -3 -73 -8 -85 -11 -11 -3 -32 -7 -46 -9 -14 -3 -36 -8 -50 -11 -14 -3 -37 -7 -51 -10 -116 -21 -360 -121 -534 -219 -22 -12 -85 -46 -140 -75 -55 -30 -113 -61 -130 -71 -16 -9 -70 -39 -120 -65 -49 -27 -108 -58 -130 -70 -64 -36 -273 -148 -360 -195 -44 -23 -102 -55 -130 -70 -27 -15 -77 -42 -110 -60 -33 -18 -114 -62 -180 -98 -66 -35 -149 -81 -185 -100 -36 -19 -92 -49 -125 -67 -179 -97 -199 -108 -415 -225 -63 -34 -153 -83 -200 -108 -47 -25 -120 -65 -164 -89 -43 -23 -80 -43 -81 -43 -6 0 -141 -84 -189 -118 -292 -202 -527 -490 -673 -827 -27 -60 -91 -254 -98 -295 -3 -17 -12 -62 -20 -101 -8 -39 -19 -101 -23 -138 -9 -87 -9 -3325 0 -3416 53 -496 309 -965 701 -1283 133 -108 217 -158 752 -446 39 -21 122 -66 185 -99 63 -33 129 -69 145 -78 17 -10 50 -28 75 -40 25 -13 74 -39 110 -59 36 -21 101 -56 145 -80 213 -114 226 -121 368 -199 28 -15 88 -47 132 -71 44 -24 127 -69 185 -100 58 -32 141 -77 185 -100 79 -42 274 -147 370 -200 211 -115 300 -160 380 -193 105 -43 250 -89 318 -101 15 -2 35 -7 45 -10 22 -6 81 -15 167 -25 76 -9 401 -6 450 3 17 4 68 13 115 22 255 46 371 96 904 384 l69 38 76 -62 c221 -178 510 -317 773 -372 259 -54 480 -63 706 -30 130 20 123 18 244 50 634 167 1143 667 1301 1276 43 167 51 234 52 430 0 261 -32 423 -132 662 -37 89 -42 110 -33 128 32 60 106 293 123 390 7 37 17 91 24 125 10 50 12 3363 2 3445 -19 152 -77 394 -114 475 -8 16 -24 55 -35 85 -54 139 -199 369 -315 499 -166 186 -334 318 -565 444 -30 16 -102 56 -160 87 -101 55 -164 89 -315 170 -38 21 -144 78 -235 127 -91 50 -194 106 -230 125 -36 19 -101 55 -145 79 -152 82 -180 98 -250 134 -60 32 -309 167 -470 255 -27 15 -90 49 -140 75 -49 26 -103 56 -120 65 -16 10 -66 37 -110 60 -44 24 -102 55 -130 70 -240 132 -367 194 -485 237 -68 25 -265 77 -338 88 -23 4 -54 9 -70 12 -30 5 -399 13 -404 8z m412 -3180 c52 -7 106 -16 120 -19 14 -3 36 -8 50 -11 163 -31 303 -90 748 -313 l434 -217 -5 -605 c-2 -333 -6 -614 -9 -625 -3 -11 -9 -40 -13 -65 -14 -84 -16 -95 -36 -173 -125 -492 -442 -913 -888 -1181 -52 -31 -95 -56 -97 -56 -2 0 -68 -35 -146 -78 -79 -43 -188 -103 -243 -132 -55 -29 -108 -58 -117 -64 -20 -12 -43 -2 -288 136 -62 34 -134 74 -280 153 -344 188 -568 385 -760 671 -48 70 -148 257 -177 329 -42 105 -95 288 -107 369 -4 21 -9 48 -11 60 -15 61 -17 136 -22 647 -5 542 -4 557 15 595 19 37 39 49 434 246 420 211 550 265 719 303 193 42 490 56 679 30z" transform="translate(0.000000,1024.000000) scale(0.100000,-0.100000)"/></g></svg>
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
width="1024.000000pt" height="1024.000000pt" viewBox="0 0 1024.000000 1024.000000"
preserveAspectRatio="xMidYMid meet">
<metadata>
Created by potrace 1.14, written by Peter Selinger 2001-2017
</metadata>
<g transform="translate(0.000000,1024.000000) scale(0.100000,-0.100000)"
fill="#000000" stroke="none">
<path d="M4958 9915 c-2 -2 -32 -6 -67 -9 -35 -3 -73 -8 -85 -11 -11 -3 -32
-7 -46 -9 -14 -3 -36 -8 -50 -11 -14 -3 -37 -7 -51 -10 -116 -21 -360 -121
-534 -219 -22 -12 -85 -46 -140 -75 -55 -30 -113 -61 -130 -71 -16 -9 -70 -39
-120 -65 -49 -27 -108 -58 -130 -70 -64 -36 -273 -148 -360 -195 -44 -23 -102
-55 -130 -70 -27 -15 -77 -42 -110 -60 -33 -18 -114 -62 -180 -98 -66 -35
-149 -81 -185 -100 -36 -19 -92 -49 -125 -67 -179 -97 -199 -108 -415 -225
-63 -34 -153 -83 -200 -108 -47 -25 -120 -65 -164 -89 -43 -23 -80 -43 -81
-43 -6 0 -141 -84 -189 -118 -292 -202 -527 -490 -673 -827 -27 -60 -91 -254
-98 -295 -3 -17 -12 -62 -20 -101 -8 -39 -19 -101 -23 -138 -9 -87 -9 -3325 0
-3416 53 -496 309 -965 701 -1283 133 -108 217 -158 752 -446 39 -21 122 -66
185 -99 63 -33 129 -69 145 -78 17 -10 50 -28 75 -40 25 -13 74 -39 110 -59
36 -21 101 -56 145 -80 213 -114 226 -121 368 -199 28 -15 88 -47 132 -71 44
-24 127 -69 185 -100 58 -32 141 -77 185 -100 79 -42 274 -147 370 -200 211
-115 300 -160 380 -193 105 -43 250 -89 318 -101 15 -2 35 -7 45 -10 22 -6 81
-15 167 -25 76 -9 401 -6 450 3 17 4 68 13 115 22 255 46 371 96 904 384 l69
38 76 -62 c221 -178 510 -317 773 -372 259 -54 480 -63 706 -30 130 20 123 18
244 50 634 167 1143 667 1301 1276 43 167 51 234 52 430 0 261 -32 423 -132
662 -37 89 -42 110 -33 128 32 60 106 293 123 390 7 37 17 91 24 125 10 50 12
3363 2 3445 -19 152 -77 394 -114 475 -8 16 -24 55 -35 85 -54 139 -199 369
-315 499 -166 186 -334 318 -565 444 -30 16 -102 56 -160 87 -101 55 -164 89
-315 170 -38 21 -144 78 -235 127 -91 50 -194 106 -230 125 -36 19 -101 55
-145 79 -152 82 -180 98 -250 134 -60 32 -309 167 -470 255 -27 15 -90 49
-140 75 -49 26 -103 56 -120 65 -16 10 -66 37 -110 60 -44 24 -102 55 -130 70
-240 132 -367 194 -485 237 -68 25 -265 77 -338 88 -23 4 -54 9 -70 12 -30 5
-399 13 -404 8z m412 -3180 c52 -7 106 -16 120 -19 14 -3 36 -8 50 -11 163
-31 303 -90 748 -313 l434 -217 -5 -605 c-2 -333 -6 -614 -9 -625 -3 -11 -9
-40 -13 -65 -14 -84 -16 -95 -36 -173 -125 -492 -442 -913 -888 -1181 -52 -31
-95 -56 -97 -56 -2 0 -68 -35 -146 -78 -79 -43 -188 -103 -243 -132 -55 -29
-108 -58 -117 -64 -20 -12 -43 -2 -288 136 -62 34 -134 74 -280 153 -344 188
-568 385 -760 671 -48 70 -148 257 -177 329 -42 105 -95 288 -107 369 -4 21
-9 48 -11 60 -15 61 -17 136 -22 647 -5 542 -4 557 15 595 19 37 39 49 434
246 420 211 550 265 719 303 193 42 490 56 679 30z"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.6 KiB

After

Width:  |  Height:  |  Size: 2.8 KiB

191
docs/index.css Normal file
View File

@@ -0,0 +1,191 @@
body {
margin: 0;
line-height: normal;
background: linear-gradient(-72.79deg, #fec9f9, #ffdbfd 0.01%, #ecfdff 64.06%);
background-size: auto;
background-repeat: no-repeat;
background-attachment: fixed;
}
@font-face {
font-family: "San Francisco";
font-weight: 400;
src: url("https://applesocial.s3.amazonaws.com/assets/styles/fonts/sanfrancisco/sanfranciscodisplay-regular-webfont.woff");
}
:root {
--font-san-francisco: "San Francisco";
--font-poppins: Poppins;
--font-size-sm: 14px;
--color-aliceblue-100: #f3f8ff;
--br-5xs: 8px;
}
.download-now {
position: relative;
font-size: var(--font-size-sm);
line-height: 19px;
font-weight: 600;
font-family: var(--font-poppins);
color: var(--color-aliceblue-100);
text-align: center;
}
.download,
.github {
cursor: pointer;
border: 0;
padding: 0;
background-color: transparent;
position: absolute;
margin-top: 597px;
border-radius: var(--br-5xs);
width: 190px;
height: 62px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
.download {
margin-left: 172px;
background: linear-gradient(90.05deg, #45bfff 26.58%, #00a7ff);
box-shadow: 0 24px 30px -16px rgba(45, 183, 255, 0.25);
}
.github {
margin-left: 392px;
background: linear-gradient(90.05deg, #424242 26.58%, #333);
box-shadow: 0 24px 30px -16px rgba(66, 66, 66, 0.25);
}
.description,
.heading {
position: absolute;
margin-top: 505px;
margin-left: 172px;
line-height: 26px;
display: inline-block;
width: 388px;
}
.heading {
margin-top: 285px;
margin-left: 166px;
font-size: 85px;
line-height: 90px;
color: #292e37;
width: 461px;
}
.byagam778 {
position: absolute;
margin-top: 219px;
margin-left: 170px;
font-size: 38px;
line-height: 50px;
font-family: 'SF Pro Text',-apple-system,BlinkMacSystemFont,var(--font-san-francisco);
color: #00acff;
cursor: pointer;
}
.content,
.preview-icon {
position: absolute;
margin-top: -93px;
margin-left: 0;
width: 890px;
height: 834px;
}
.content {
transform: translate(-50%, -50%);
margin-left: 30%;
margin-top: 21.5%;
}
.preview-icon {
position: absolute;
margin-top: 23%;
margin-left: 68%;
transform: translate(-50%, -50%);
width: 708px;
height: 447px;
object-fit: cover;
}
.ms-365-electron {
width: 100%;
height: 696px;
flex-direction: column;
align-items: center;
justify-content: flex-start;
text-align: left;
font-size: 18px;
color: #525d73;
font-family: var(--font-poppins);
}
@media (max-width: 768px) {
.preview-icon {
width: 78%;
height: auto;
margin-top: 45%;
margin-left: 50%;
transform: translate(-50%, -50%);
}
.content {
margin-top: 77%;
}
.heading {
text-align: center;
font-size: 30px;
height: auto;
margin-top: 56%;
margin-left: 59%;
transform: translate(-50%, -50%);
}
.byagam778 {
text-align: center;
width: 100%;
font-size: 26px;
height: auto;
margin-top: 50%;
margin-left: 59%;
transform: translate(-50%, -50%);
}
.description {
text-align: center;
width: 40%;
font-size: 20px;
height: auto;
margin-top: 65%;
margin-left: 59%;
transform: translate(-50%, -50%);
}
.github {
text-align: center;
font-size: 20px;
margin-top: 85%;
margin-left: 59%;
transform: translate(-50%, -50%);
}
.download {
text-align: center;
font-size: 20px;
margin-top: 77%;
margin-left: 59%;
transform: translate(-50%, -50%);
}
.download-now {
font-size: 14px;
}
}

91
docs/index.html Normal file
View File

@@ -0,0 +1,91 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="initial-scale=1, width=device-width" />
<title>MS-365-Electron</title>
<link rel="stylesheet" href="./index.css" />
<link
rel="apple-touch-icon"
sizes="180x180"
href="./favicons/apple-touch-icon.png"
/>
<link
rel="icon"
type="image/png"
sizes="32x32"
href="./favicons/favicon-32x32.png"
/>
<link
rel="icon"
type="image/png"
sizes="16x16"
href="./favicons/favicon-16x16.png"
/>
<link rel="manifest" href="./favicons/site.webmanifest" />
<link
rel="mask-icon"
href="./favicons/safari-pinned-tab.svg"
color="#5bbad5"
/>
<link rel="shortcut icon" href="./favicons/favicon.ico" />
<meta name="apple-mobile-web-app-title" content="MS-365-Electron" />
<meta name="application-name" content="MS-365-Electron" />
<meta name="msapplication-TileColor" content="#603cba" />
<meta name="msapplication-config" content="./favicons/browserconfig.xml" />
<meta name="theme-color" content="#ffffff" />
<link
rel="stylesheet"
href="https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap"
/>
<link
rel="stylesheet"
href="https://fonts.googleapis.com/css2?family=Seaweed Script:wght@400&display=swap"
/>
</head>
<body>
<div class="ms-365-electron">
<div class="content">
<button class="download" id="download">
<div class="download-now">
Download Now:
<div id="release-tag"></div>
</div>
</button>
<button class="github" id="gitHub">
<div class="download-now">View on GitHub</div>
</button>
<div class="description">
Unofficial Microsoft 365 Web Desktop Wrapper made with Electron
</div>
<b class="heading">MS-365-Electron</b>
<div class="byagam778" id="byagam778">By @agam778</div>
</div>
<img class="preview-icon" alt="" src="./public/preview.png" />
</div>
<script src="./index.js"></script>
<script>
var download = document.getElementById("download");
if (download) {
download.addEventListener("click", function () {
window.open("https://github.com/agam778/MS-365-Electron/releases");
});
}
var gitHub = document.getElementById("gitHub");
if (gitHub) {
gitHub.addEventListener("click", function () {
window.open("https://github.com/agam778/MS-365-Electron/");
});
}
var byagam778 = document.getElementById("byagam778");
if (byagam778) {
byagam778.addEventListener("click", function () {
window.open("https://github.com/agam778");
});
}
</script>
</body>
</html>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 586 KiB

After

Width:  |  Height:  |  Size: 593 KiB

View File

@@ -14,7 +14,6 @@
},
"build": {
"extraFiles": [
"/assets/icons",
"LICENSE"
],
"appId": "com.agampreet.ms-365-electron",
@@ -74,6 +73,7 @@
"dependencies": {
"@cliqz/adblocker-electron": "^1.26.6",
"@xhayper/discord-rpc": "^1.0.17",
"about-window": "^1.15.2",
"axios": "^1.4.0",
"check-internet-connected": "^2.0.6",
"cross-fetch": "^3.1.6",

View File

@@ -524,6 +524,13 @@ __metadata:
languageName: node
linkType: hard
"about-window@npm:^1.15.2":
version: 1.15.2
resolution: "about-window@npm:1.15.2"
checksum: 0e528f6312d2dc3801926f056230e5c6c253f4be16449b4c01b115a2dd24e8b6897f8ba8c07880097415936b9c40a04c10954558af3a6d05d76a11d8a07875d8
languageName: node
linkType: hard
"acorn-jsx@npm:^5.3.2":
version: 5.3.2
resolution: "acorn-jsx@npm:5.3.2"
@@ -2744,6 +2751,7 @@ __metadata:
dependencies:
"@cliqz/adblocker-electron": ^1.26.6
"@xhayper/discord-rpc": ^1.0.17
about-window: ^1.15.2
axios: ^1.4.0
check-internet-connected: ^2.0.6
cross-fetch: ^3.1.6