From 5d786fa5b53148af677e1e5280eba507a533c88e Mon Sep 17 00:00:00 2001 From: TropiiDev Date: Wed, 5 Mar 2025 13:45:41 -0500 Subject: [PATCH] Implement a copyurl.js file --- CHANGELOG.md | 9 ++++++--- copyurl.js | 5 +++++ main.html | 13 ++++++++++++- style.css | 3 +++ 4 files changed, 26 insertions(+), 4 deletions(-) create mode 100644 copyurl.js create mode 100644 style.css diff --git a/CHANGELOG.md b/CHANGELOG.md index a6592d2..9a7c1b9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,7 @@ ## Changelog -## 0.0.1 -- Alpha release. -- Added the starter functionality. +## 0.0.2 +# Alpha release + +- Added a copyurl.js file to copy the url. +- Added a css style. will be updated more later. +- Updated the main.html file to make the extension look better. diff --git a/copyurl.js b/copyurl.js new file mode 100644 index 0000000..7132412 --- /dev/null +++ b/copyurl.js @@ -0,0 +1,5 @@ +const url = window.location.href; +const clipboard = navigator.clipboard; +clipboard.writeText(url); + +console.log(`Wrote URL: ${url}`); diff --git a/main.html b/main.html index d2e07be..2b97bc8 100644 --- a/main.html +++ b/main.html @@ -1,5 +1,16 @@ + + + -

Copy URL

+

Copy the current url

+

+ The current URL was copied when you opened this extension. Thank + you! +

+ +

Made with love by Tropii.

+ Website + diff --git a/style.css b/style.css new file mode 100644 index 0000000..2d40f2f --- /dev/null +++ b/style.css @@ -0,0 +1,3 @@ +* { + background-color: gray; +}