Skip to content

Commit

Permalink
Update copy icon
Browse files Browse the repository at this point in the history
  • Loading branch information
achhabra2 committed Jan 4, 2022
1 parent cf4e9c7 commit 8e688e3
Show file tree
Hide file tree
Showing 7 changed files with 25 additions and 5 deletions.
1 change: 1 addition & 0 deletions build/darwin/Info.plist
Expand Up @@ -14,5 +14,6 @@
<key>LSApplicationCategoryType</key><string>public.app-category.utilities</string>
<key>NSHighResolutionCapable</key><string>true</string>
<key>NSHumanReadableCopyright</key><string>Licensed Under the GPLv3</string>
<key>ITSAppUsesNonExemptEncryption</key><false />
</dict>
</plist>
1 change: 1 addition & 0 deletions frontend/dist/assets/images/copy-regular.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion frontend/dist/bundle.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion frontend/dist/bundle.js.map

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions frontend/src/assets/images/copy-regular.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 3 additions & 1 deletion frontend/src/sender.svelte
Expand Up @@ -183,6 +183,7 @@
{#if sendCode}
<div class="mx-auto mt-2" transition:slide>
<label for="sendCode" class="send-input-label">Send Code</label>
<div class="flex flex-row">
<input
id="sendCode"
readonly
Expand All @@ -191,7 +192,8 @@
value={sendCode}
class="send-input mt-1"
/>
<button class="send-button" on:click={copyCode}>📄</button>
<button class="copy-button mt-1 ml-1" on:click={copyCode}><div class="copy-icon"></div></button>
</div>
</div>
{/if}
</div>
Expand Down
19 changes: 17 additions & 2 deletions frontend/src/styles.pcss
Expand Up @@ -17,14 +17,19 @@ div {
@apply rounded-lg p-2 bg-green-500 duration-150 text-gray-200 hover:bg-green-700 active:bg-green-800;
}
.send-input {
@apply border border-transparent focus:outline-none focus:ring-2 focus:ring-green-300 focus:border-transparent bg-gray-700 text-gray-200 rounded-md shadow-inner shadow-md;
@apply border border-transparent focus:outline-none focus:ring-2 focus:ring-green-300 focus:border-transparent bg-gray-700 text-gray-200 rounded-l-md shadow-inner shadow-md;
}
.send-input-label {
@apply block text-sm text-gray-200;
@apply block text-sm text-gray-300;
}
.send-button {
@apply rounded-lg px-4 py-2 bg-green-600 duration-150 text-gray-200 hover:bg-green-700 disabled:opacity-50 active:bg-green-800;
}

.copy-button {
@apply rounded-r-md px-2 py-2 bg-green-600 duration-150 text-gray-200 hover:bg-green-700 disabled:opacity-50 active:bg-green-800 w-10;
}

.receive-input {
@apply border border-transparent focus:outline-none focus:ring-2 focus:ring-green-300 focus:border-transparent bg-gray-800 text-gray-200 rounded-l-md shadow-inner shadow-md;
}
Expand Down Expand Up @@ -96,6 +101,16 @@ div {
background-repeat: no-repeat;
}

.copy-icon {
height: 1.5rem;
width: 1.5rem;
background-repeat: no-repeat;
mask-image: url("./assets/images/copy-regular.svg");
mask-repeat: no-repeat;
mask-position: center;
@apply bg-gray-900;
}

.receive-tab-icon {
mask-image: url("./assets/images/download-solid.svg");
mask-repeat: no-repeat;
Expand Down

0 comments on commit 8e688e3

Please sign in to comment.