Skip to content

Commit

Permalink
Added license and privacy section
Browse files Browse the repository at this point in the history
  • Loading branch information
dinoosauro committed Jun 10, 2024
1 parent f9d0b98 commit 9b3ced1
Show file tree
Hide file tree
Showing 6 changed files with 54 additions and 2 deletions.
20 changes: 20 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
MIT License

Copyright (c) 2024 Dinoosauro

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
Convert images frmo various formats to JPG/PNG/WebP, by resizing them and adding
filters.

Try it: https://dinoosauro.github.io/image-converter/

Looking for the old, vanilla HTML/CSS/JS version? Check the
[old-js-website repository](https://github.com/Dinoosauro/image-converter/tree/old-javascript-website)

## How it works

### Choose a file
Expand Down Expand Up @@ -56,3 +61,12 @@ In the settings, you can:
specific folder selected by the user (Currently available only on
Chromium-based browsers)
- See the open source licenses

## Progressive Web App You can install image-converter as a Progressive Web App.
With this, you'll be able to use it offline, and you'll be also be able to open
files from the system's file explorer.

## Privacy

Your images are locally elaborated on your device, and nothing is sent to an
external server.
2 changes: 2 additions & 0 deletions src/App.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import Assets from "./lib/Styles/Assets.svelte";
import TitleIcon from "./lib/Styles/TitleIcon.svelte";
import { updateAccentImage } from "./Scripts/ImageContentHandler";
import Privacy from "./lib/Privacy.svelte";
$: dialogShow = 0;
const fileSystemAPIId = `Checkbox-${Math.random().toString().substring(2)}`;
afterUpdate(() => {
Expand Down Expand Up @@ -119,6 +120,7 @@
{#if !window.matchMedia("(display-mode: standalone)").matches}
<PWAPrompt></PWAPrompt>
{/if}
<Privacy></Privacy>
</div>
{:else if $conversionStatus === 1}
<ImagePicker></ImagePicker><br />
Expand Down
3 changes: 2 additions & 1 deletion src/Scripts/ImageContentHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ export function ImageRes(key: AssetsType) {
folder: `<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"><path fill="${color}" d="M3.5 6.25V8h4.629a.75.75 0 0 0 .53-.22l1.53-1.53-1.53-1.53a.75.75 0 0 0-.53-.22H5.25A1.75 1.75 0 0 0 3.5 6.25Zm-1.5 0A3.25 3.25 0 0 1 5.25 3h2.879a2.25 2.25 0 0 1 1.59.659L11.562 5.5h7.189A3.25 3.25 0 0 1 22 8.75v9A3.25 3.25 0 0 1 18.75 21H5.25A3.25 3.25 0 0 1 2 17.75V6.25ZM3.5 9.5v8.25c0 .966.784 1.75 1.75 1.75h13.5a1.75 1.75 0 0 0 1.75-1.75v-9A1.75 1.75 0 0 0 18.75 7h-7.19L9.72 8.841a2.25 2.25 0 0 1-1.591.659H3.5Z"/></svg>`,
paragraph: `<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"><path fill="${color}" d="M16.5 8a4.25 4.25 0 0 0 0 8.5h.5v4.75a.75.75 0 0 0 1.5 0V9.5h1v11.75a.75.75 0 0 0 1.5 0V9.5h.25a.75.75 0 0 0 0-1.5H16.5Zm0 1.5h.5V15h-.5a2.75 2.75 0 1 1 0-5.5ZM2.75 5a.75.75 0 0 0 0 1.5h18.5a.75.75 0 0 0 0-1.5H2.75Zm0 5a.75.75 0 0 0 0 1.5h8.553c.076-.53.23-1.034.452-1.5H2.75Zm9.277 5H2.75a.75.75 0 0 0 0 1.5h10.667a5.278 5.278 0 0 1-1.39-1.5Z"/></svg>`,
apps: `<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"><path fill="${color}" d="m18.492 2.33 3.179 3.18a2.25 2.25 0 0 1 0 3.182l-2.584 2.584A2.25 2.25 0 0 1 21 13.5v5.25A2.25 2.25 0 0 1 18.75 21H5.25A2.25 2.25 0 0 1 3 18.75V5.25A2.25 2.25 0 0 1 5.25 3h5.25a2.25 2.25 0 0 1 2.225 1.915l2.585-2.585a2.25 2.25 0 0 1 3.182 0ZM4.5 18.75c0 .415.336.75.75.75h5.999l.001-6.75H4.5v6Zm8.249.75h6.001a.75.75 0 0 0 .75-.75V13.5a.75.75 0 0 0-.75-.75h-6.001v6.75ZM10.5 4.5H5.25a.75.75 0 0 0-.75.75v6h6.75v-6a.75.75 0 0 0-.75-.75Zm2.25 4.81v1.94h1.94l-1.94-1.94Zm3.62-5.918L13.193 6.57a.75.75 0 0 0 0 1.061l3.179 3.179a.75.75 0 0 0 1.06 0l3.18-3.179a.75.75 0 0 0 0-1.06l-3.18-3.18a.75.75 0 0 0-1.06 0Z"/></svg>`,
imgmultiple: `<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"><path fill="${color}" d="M13.748 8.996a1.248 1.248 0 1 0 0-2.496 1.248 1.248 0 0 0 0 2.496ZM6.25 3A3.25 3.25 0 0 0 3 6.25v9a3.25 3.25 0 0 0 3.25 3.25h9a3.25 3.25 0 0 0 3.25-3.25v-9A3.25 3.25 0 0 0 15.25 3h-9ZM4.5 6.25c0-.966.784-1.75 1.75-1.75h9c.966 0 1.75.784 1.75 1.75v9c0 .231-.045.452-.126.654l-4.587-4.291a2.25 2.25 0 0 0-3.074 0l-4.587 4.29a1.745 1.745 0 0 1-.126-.653v-9Zm6.762 6.458 4.505 4.214c-.163.05-.337.078-.517.078h-9c-.18 0-.354-.027-.517-.078l4.504-4.214a.75.75 0 0 1 1.025 0ZM8.75 21a3.247 3.247 0 0 1-2.74-1.5h9.74a3.75 3.75 0 0 0 3.75-3.75V6.011a3.248 3.248 0 0 1 1.5 2.74v7C21 18.65 18.65 21 15.75 21h-7Z"/></svg>`
imgmultiple: `<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"><path fill="${color}" d="M13.748 8.996a1.248 1.248 0 1 0 0-2.496 1.248 1.248 0 0 0 0 2.496ZM6.25 3A3.25 3.25 0 0 0 3 6.25v9a3.25 3.25 0 0 0 3.25 3.25h9a3.25 3.25 0 0 0 3.25-3.25v-9A3.25 3.25 0 0 0 15.25 3h-9ZM4.5 6.25c0-.966.784-1.75 1.75-1.75h9c.966 0 1.75.784 1.75 1.75v9c0 .231-.045.452-.126.654l-4.587-4.291a2.25 2.25 0 0 0-3.074 0l-4.587 4.29a1.745 1.745 0 0 1-.126-.653v-9Zm6.762 6.458 4.505 4.214c-.163.05-.337.078-.517.078h-9c-.18 0-.354-.027-.517-.078l4.504-4.214a.75.75 0 0 1 1.025 0ZM8.75 21a3.247 3.247 0 0 1-2.74-1.5h9.74a3.75 3.75 0 0 0 3.75-3.75V6.011a3.248 3.248 0 0 1 1.5 2.74v7C21 18.65 18.65 21 15.75 21h-7Z"/></svg>`,
shield: `<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"><path fill="${color}" d="M3 5.75A.75.75 0 0 1 3.75 5c2.663 0 5.258-.943 7.8-2.85a.75.75 0 0 1 .9 0C14.992 4.057 17.587 5 20.25 5a.75.75 0 0 1 .75.75V11c0 5.001-2.958 8.676-8.725 10.948a.75.75 0 0 1-.55 0C5.958 19.676 3 16 3 11V5.75Zm1.5.728V11c0 4.256 2.453 7.379 7.5 9.442 5.047-2.063 7.5-5.186 7.5-9.442V6.478c-2.577-.152-5.08-1.09-7.5-2.8-2.42 1.71-4.923 2.648-7.5 2.8Z"/></svg>`
}[key]
}
export function setAccentImage(img: HTMLImageElement, str: AssetsType) {
Expand Down
2 changes: 1 addition & 1 deletion src/Scripts/Storage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export interface FileConversion {
quality?: number,
mimeType?: string
}
export type AssetsType = "settings" | "documentadd" | "resizeimage" | "imagesparkle" | "image" | "color" | "folder" | "paragraph" | "apps" | "imgmultiple";
export type AssetsType = "settings" | "documentadd" | "resizeimage" | "imagesparkle" | "image" | "color" | "folder" | "paragraph" | "apps" | "imgmultiple" | "shield";
import { writable } from "svelte/store";

export let conversionStatus = writable(0);
Expand Down
15 changes: 15 additions & 0 deletions src/lib/Privacy.svelte
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<script>
import TitleIcon from "./Styles/TitleIcon.svelte";
</script>

<div class="card">
<TitleIcon asset="shield">Privacy:</TitleIcon>
<p>
Every image is elaborated locally, and nothing is shared to an external
server. Connections are made to Google Fonts to fetch the 'Work Sans'
font and to GitHub for downloading the necessary scripts to make
image-converter work. After these contents have been downloaded, you're
able to use image-convert completely offline. image-converter does not
share any data with them.
</p>
</div>

0 comments on commit 9b3ced1

Please sign in to comment.