From 831cbcfa5d9f07ecac734bf45d1fe21c83624314 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=D1=81=D0=B8=D0=BD=D0=B5=D1=87=D0=BA=D0=B0=20=E2=99=A1?=
<63897347+ktnk-dev@users.noreply.github.com>
Date: Tue, 13 May 2025 23:33:10 +0300
Subject: [PATCH] code separation, updater, simple docs
---
README.md | 9 ++---
docs/INSTALL_CHROME.md | 10 ++++++
docs/INSTALL_FIREFOX.md | 9 +++++
manifest.json | 4 ---
src/css/update.css | 24 +++++++++++++
src/index.html | 6 ++--
src/js/builtin.js | 75 ++++++++++++++++++++++++++++++++++++++++
src/js/main.js | 76 -----------------------------------------
src/js/storage.js | 4 +--
src/js/update.js | 21 ++++++++++++
10 files changed, 147 insertions(+), 91 deletions(-)
create mode 100644 docs/INSTALL_CHROME.md
create mode 100644 docs/INSTALL_FIREFOX.md
create mode 100644 src/css/update.css
create mode 100644 src/js/builtin.js
create mode 100644 src/js/update.js
diff --git a/README.md b/README.md
index 7c1baea..0c3a05b 100644
--- a/README.md
+++ b/README.md
@@ -1,9 +1,4 @@

-# How to install
-1. Install [`this`](https://fonts.google.com/share?selection.family=Fira+Code:wght@300..700|Nunito:ital,wght@0,200..1000;1,200..1000|Playfair+Display:ital,wght@0,400..900;1,400..900) fonts
-2. Clone repository
-3. Go to `chrome://extensions`
-4. Enable `Developer mode`
-5. Click `Load unpacked` > select repo's folder
-6. Enjoy your new tab/home page
\ No newline at end of file
+# Install
+[`Chrome-based browser`](./docs/INSTALL_CHROME.md) [`Firefox-based browser`](./docs/INSTALL_FIREFOX.md)
diff --git a/docs/INSTALL_CHROME.md b/docs/INSTALL_CHROME.md
new file mode 100644
index 0000000..8d84f9e
--- /dev/null
+++ b/docs/INSTALL_CHROME.md
@@ -0,0 +1,10 @@
+[← Back](../)
+
+# Install to Chrome-based browser
+1. Install [`this`](https://fonts.google.com/share?selection.family=Fira+Code:wght@300..700|Nunito:ital,wght@0,200..1000;1,200..1000|Playfair+Display:ital,wght@0,400..900;1,400..900) fonts
+2. Download [`this`](https://github.com/ktnk-dev/LittleHome/archive/refs/heads/main.zip) archive
+3. Extract it somewhere
+4. Go to `chrome://extensions`
+5. Enable `Developer mode`
+6. Click `Load unpacked` > select your exctracted folder (should me `LittleHome-main`)
+7. Enjoy your new tab/home page
\ No newline at end of file
diff --git a/docs/INSTALL_FIREFOX.md b/docs/INSTALL_FIREFOX.md
new file mode 100644
index 0000000..e3427f1
--- /dev/null
+++ b/docs/INSTALL_FIREFOX.md
@@ -0,0 +1,9 @@
+[← Back](../)
+
+# Install to Firefox-based browser
+1. Install [`this`](https://fonts.google.com/share?selection.family=Fira+Code:wght@300..700|Nunito:ital,wght@0,200..1000;1,200..1000|Playfair+Display:ital,wght@0,400..900;1,400..900) fonts
+2. Download [`this`](https://github.com/ktnk-dev/LittleHome/archive/refs/heads/main.zip) archive
+3. Go to `about:debugging`
+4. Select `This Firefox`
+5. Click `Load Temporary Add-on...` > select downloaded ZIP archive (should me `LittleHome-main.zip`)
+6. Enjoy your new tab/home page
\ No newline at end of file
diff --git a/manifest.json b/manifest.json
index 4a1ceee..6a388f0 100644
--- a/manifest.json
+++ b/manifest.json
@@ -22,10 +22,6 @@
""
],
"js": [
- "src/js/abstract.js",
- "src/js/storage.js",
- "src/js/bang.js",
- "src/js/main.js"
]
}
]
diff --git a/src/css/update.css b/src/css/update.css
new file mode 100644
index 0000000..7859ee5
--- /dev/null
+++ b/src/css/update.css
@@ -0,0 +1,24 @@
+#update {
+ position: fixed;
+ bottom: 0;
+ right: 0;
+ font-size: 13px;
+ font-family: 'Nunito';
+ background: rgba(255,255,255,.1);
+ border-radius: 100px;
+ margin: 10px;
+ display: flex;
+ z-index: 20;
+ transition: transform .5s;
+} #update > * {
+ padding: 5px 10px;
+} #update > a {
+ text-decoration: none;
+ background: rgba(255,255,255,.1);
+ border-radius: 100px;
+ cursor: pointer;
+}
+
+#update.hidden {
+ transform: translateY(40px);
+}
\ No newline at end of file
diff --git a/src/index.html b/src/index.html
index 0d9361d..71f416d 100644
--- a/src/index.html
+++ b/src/index.html
@@ -5,10 +5,10 @@
Home
-
+
@@ -17,10 +17,12 @@
Search via Google
-
+
+
+