Skip to content
This repository has been archived by the owner on Mar 18, 2023. It is now read-only.

Commit

Permalink
merge
Browse files Browse the repository at this point in the history
  • Loading branch information
filiptronicek committed Nov 24, 2019
2 parents af702c3 + d2ec912 commit 7c73c99
Show file tree
Hide file tree
Showing 7 changed files with 72 additions and 51 deletions.
2 changes: 1 addition & 1 deletion assets/css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ body {
margin: 0;
max-height: 100vh !important;
max-width: 100vw !important;
}
}
28 changes: 16 additions & 12 deletions assets/css/recieve.css
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
#code {
margin-top: 20vh;
transition-duration: 400ms;
text-align: center;
box-sizing: border-box;
width: 80vw;
height: 50vh;
margin-left: 10vw;
font-size: 30vmin;
border: 4px solid #ffffff;
margin-top: 20vh;
transition-duration: 400ms;
text-align: center;
box-sizing: border-box;
width: 80vw;
height: 50vh;
margin-left: 10vw;
font-size: 30vmin;
border: 4px solid #ffffff;
}
#result {
font-size: 10vmin;
text-align: center;
}
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
width: 100vw;
font-size: 10vmin;
text-align: center;
}
9 changes: 9 additions & 0 deletions assets/css/title-bar.css
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ body {
display: flex;
width: 100%;
height: 50px;
overflow: hidden;
}

.menu-button-container {
Expand Down Expand Up @@ -71,3 +72,11 @@ body {
height: 25px;
border-radius: 50px;
}
img.menu-button {
transition-duration: 500ms;

}
img.menu-button:hover {
transition-duration: 500ms;
transform: rotate(90deg);
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Interclip",
"version": "0.0.7",
"version": "0.1.0",
"description": "Interclip for desktop",
"repository": "https://github.com/aperta-principium/Interclip-desktop",
"main": "main.js",
Expand Down
68 changes: 34 additions & 34 deletions src/clip.html
Original file line number Diff line number Diff line change
@@ -1,53 +1,53 @@
<!DOCTYPE html>
<html>

<head>
<meta charset="UTF-8">
<head>
<meta charset="UTF-8" />
<title>Interclip for Desktop</title>
<link rel="stylesheet" href="../assets/css/main.css">
<link rel="stylesheet" href="../assets/css/clip.css">
<link rel="stylesheet" href="../assets/css/dark.css">
<link rel="stylesheet" href="../assets/css/title-bar.css">
<link rel="stylesheet" href="../assets/css/main.css" />
<link rel="stylesheet" href="../assets/css/clip.css" />
<link rel="stylesheet" href="../assets/css/dark.css" />
<link rel="stylesheet" href="../assets/css/title-bar.css" />

<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline';" />
</head>
<div class="title-bar">
<meta
http-equiv="Content-Security-Policy"
content="script-src 'self' 'unsafe-inline';"
/>
</head>
<div class="title-bar">
<div class="menu-button-container">
<img src="../assets/icons/png/64.png"
id="menu-button"
class="menu-button"
/>
<a href="get.html">
<img
src="../assets/icons/png/64.png"
id="menu-button"
class="menu-button"
/>
</a>
</div>
<div class="app-name-container">
<p>Interclip Desktop</p>
</div>
<div class="window-controls-container">
<button
id="minimize-button"
class="minimize-button"
/>
<button
id="min-max-button"
class="min-max-button"
/>
<button
id="close-button"
class="close-button"
/>
<button id="minimize-button" class="minimize-button" />
<button id="min-max-button" class="min-max-button" />
<button id="close-button" class="close-button" />
</div>
</div>
<body id="body">
<body id="body">
<center>
<span class="center code" id="code"></span>
<span class="center code" id="code"></span>
</center>
<div name="urlform" id="content">

<input type="text" name="input" style="text-align:center;" class="input" id="search-input" autofocus>

<input
type="text"
name="input"
style="text-align:center;"
class="input"
id="search-input"
autofocus
/>
</div>

<script src="titlebar.js"></script>
<script src="clip.js"></script>
</body>

</html>
</body>
</html>
9 changes: 7 additions & 2 deletions src/clip.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
const electron = require("electron");
const path = require("path");
const Mousetrap = require("mousetrap");
const { clipboard, remote, ipcRenderer, dialog } = require("electron");
const { clipboard, remote, ipcRenderer, dialog, shell } = require("electron");

function openExtLink(url) {
shell.openExternal(url);

}

function isKeyPressed(event, expectedKey, expectedCode) {
const code = event.which || event.keyCode;
Expand Down Expand Up @@ -31,7 +36,7 @@ function sendURL(urlInput = document.getElementById("search-input").value) {
ipcRenderer.on("asynchronous-reply", (event, code) => {
if (code != "") {
document.getElementById("code").innerHTML =
"code: <span id='theCode'>" + code + "</span>";
"code: <span id='theCode'>" + code + "</span> <br> <span id='openExt' onClick='openExtLink("+code+")'>Open in browser</span>";
} else {
console.log("Code is not valid");
alert(code);
Expand Down
5 changes: 4 additions & 1 deletion src/get.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,14 @@
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline';" />
</head>
<div class="title-bar">
<div class="menu-button-container">
<div class="menu-button-container">
<a href="clip.html">

<img src="../assets/icons/png/64.png"
id="menu-button"
class="menu-button"
/>
</a>
</div>
<div class="app-name-container">
<p>Interclip Desktop</p>
Expand Down

0 comments on commit 7c73c99

Please sign in to comment.