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

Commit

Permalink
disable telegram/backend interactions
Browse files Browse the repository at this point in the history
  • Loading branch information
avoonix committed Mar 2, 2024
1 parent eb85f7e commit e0c84a9
Show file tree
Hide file tree
Showing 28 changed files with 3,420 additions and 3,716 deletions.
16 changes: 9 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
> [!NOTE]
> I no longer have fun working on this project, and I don't see myself supporting it any longer. Importing and exporting to/from JSON should continue to work, but the telegram bot has been disabled.
<p align="center">
<a href="https://stickers.avoonix.com/">
<img width="250" alt="Avoo's Sticker Stash Logo" src="./packages/frontend/public/favicon.svg">
Expand All @@ -14,6 +17,9 @@ Use the [web app](https://stickers.avoonix.com/) or try the [telegram bot](https

## Examples

> [!NOTE]
> I no longer have fun working on this project, and I don't see myself supporting it any longer. Importing and exporting to/from JSON should continue to work, but the telegram bot has been disabled.
<p align="center">
<img width="200" alt="Blue Paws Sticker" src="./examples/furry-telegram-sticker-animated-paws-blue-pastel-beans.gif">
<img width="200" alt="Petting Pink Fox Sticker" src="./examples/furry-telegram-sticker-animated-petting-petpet-pink-fox.gif">
Expand All @@ -26,19 +32,15 @@ Use the [web app](https://stickers.avoonix.com/) or try the [telegram bot](https

## Library

> [!NOTE]
> I no longer have fun working on this project, and I don't see myself supporting it any longer. Importing and exporting to/from JSON should continue to work, but the telegram bot has been disabled.
There's also a npm library for creating stickers:

- Playground: https://sticker-playground.netlify.app/
- Package: https://www.npmjs.com/package/tg-sticker-creator
- Docs: https://avoonix.github.io/tg-sticker-creator/docs/index.html

# Support

Like the project? Please consider supporting it by filing bug reports, contributing, or donating to help improve it.

[![donation link](https://i.avoonix.com/patreon/avoonix-become-a-patron-button.png)](https://avoonix.com/support)


<!-- ## Web App
[here](./packages/frontend)
Expand Down
3 changes: 1 addition & 2 deletions packages/frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@
"@types/pako": "^2.0.0",
"@types/seedrandom": "^3.0.2",
"@types/tinycolor2": "^1.4.3",
"canvas": "^2.10.1",
"ccapture.js": "^1.1.0",
"copy-webpack-plugin": "^11.0.0",
"downloadjs": "^1.4.7",
Expand All @@ -100,7 +99,7 @@
"react-dom": "18.2.0",
"react-intersection-observer": "^9.4.0",
"seedrandom": "^3.0.5",
"tg-sticker-creator": "workspace:0.2.0",
"tg-sticker-creator": "workspace:0.3.0",
"tinycolor2": "^1.4.2",
"webpack": "^5.74.0"
},
Expand Down
Binary file added packages/frontend/public/sticker_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_10.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_11.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_12.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_13.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_4.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_5.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_6.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_7.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_8.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added packages/frontend/public/sticker_9.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
77 changes: 0 additions & 77 deletions packages/frontend/src/modules/export/AddToSetButton.tsx

This file was deleted.

47 changes: 2 additions & 45 deletions packages/frontend/src/modules/export/auth.ts
Original file line number Diff line number Diff line change
@@ -1,48 +1,5 @@
import { atom, useSetAtom } from "jotai";

export interface Auth {
type?: "web-app" | "telegram-login";
data?: string; // data submitted to server for validation
name?: string;
photoUrl?: string;
}
export interface Auth {}

export const getAuthData = (): Auth => {
const telegram = (typeof window !== "undefined" ? (window as any) : {})
?.Telegram?.WebApp;

if (telegram?.initDataUnsafe?.user)
return {
data: telegram?.initData,
name:
telegram?.initDataUnsafe?.user?.first_name ||
telegram?.initDataUnsafe?.user?.username ||
"User",
type: "web-app",
};
if (typeof localStorage === "undefined") return {};
const data = localStorage.getItem("auth-data");
if (!data) return {};
const parsed = JSON.parse(data);

return {
data,
type: "telegram-login",
name: parsed.username || parsed.first_name || "user",
photoUrl: parsed.photo_url,
};
};

export const useUpdateAuthData = () => {
const set = useSetAtom(authAtom);
const updateAuthData = (data: string) => {
localStorage.setItem("auth-data", data);
set(getAuthData());
};

return {
updateAuthData,
};
};

export const authAtom = atom<Auth>(getAuthData());
export const authAtom = atom<Auth>({});
64 changes: 0 additions & 64 deletions packages/frontend/src/modules/export/requests.ts

This file was deleted.

4 changes: 4 additions & 0 deletions packages/frontend/src/modules/misc/Introduction.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ import { FC } from "react";
const Introduction: FC = (props) => {
return (
<Well>
<p style={{padding: "8px", margin: "8px", fontSize: "1.5em", color: "orange", borderLeft: "0.2em solid orange", maxWidth: "50%"}}>

I no longer have fun working on this project, and I don't see myself supporting it any longer. Importing and exporting to/from JSON should continue to work, but the telegram bot has been disabled.
</p>
<p>
Pick a template that most closely matches your character to get started
and tweak it to your liking. The sticker type can be changed later.
Expand Down
28 changes: 14 additions & 14 deletions packages/frontend/src/modules/stickers/globalStickers.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/headpats/8775b344-5ad5-4d65-99d5-b81f8e679e12/sticker.png",
"url": "/sticker_13.png",
"emojis": [
{ "name": "waving", "emoji": "👋" },
{ "name": "love", "emoji": "🥰" },
Expand All @@ -11,7 +11,7 @@
"settingId": "8775b344-5ad5-4d65-99d5-b81f8e679e12"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/popping/8775b344-5ad5-4d65-99d5-b81f8e679e12/sticker.png",
"url": "/sticker_12.png",
"emojis": [
{ "name": "cat", "emoji": "🐱" },
{ "name": "open mouth", "emoji": "😮" },
Expand All @@ -24,7 +24,7 @@
"settingId": "8775b344-5ad5-4d65-99d5-b81f8e679e12"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/paws/8775b344-5ad5-4d65-99d5-b81f8e679e12/sticker.png",
"url": "/sticker_11.png",
"emojis": [
{ "name": "paws", "emoji": "🐾" },
{ "name": "feet", "emoji": "👣" }
Expand All @@ -34,21 +34,21 @@
"settingId": "8775b344-5ad5-4d65-99d5-b81f8e679e12"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/halloween/8775b344-5ad5-4d65-99d5-b81f8e679e12/sticker.png",
"url": "/sticker_10.png",
"emojis": [{ "name": "eyes", "emoji": "👀" }],
"name": "Oliver - Halloween",
"stickerId": "halloween",
"settingId": "8775b344-5ad5-4d65-99d5-b81f8e679e12"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/heart/8775b344-5ad5-4d65-99d5-b81f8e679e12/sticker.png",
"url": "/sticker_9.png",
"emojis": [{ "name": "heart", "emoji": "❤️" }],
"name": "Oliver - Heart",
"stickerId": "heart",
"settingId": "8775b344-5ad5-4d65-99d5-b81f8e679e12"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/hug/8775b344-5ad5-4d65-99d5-b81f8e679e12/sticker.png",
"url": "/sticker_8.png",
"emojis": [
{ "name": "hugging", "emoji": "🫂" },
{ "name": "open hands", "emoji": "🤗" }
Expand All @@ -58,7 +58,7 @@
"settingId": "8775b344-5ad5-4d65-99d5-b81f8e679e12"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/attribution/8775b344-5ad5-4d65-99d5-b81f8e679e12/sticker.png",
"url": "/sticker_7.png",
"emojis": [
{ "name": "info", "emoji": "ℹ️" },
{ "name": "writing", "emoji": "✍️" }
Expand All @@ -68,7 +68,7 @@
"settingId": "8775b344-5ad5-4d65-99d5-b81f8e679e12"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/headpats/b28b1f41-10aa-4e37-a0c3-3bcca310cbe5/sticker.png",
"url": "/sticker_6.png",
"emojis": [
{ "name": "waving", "emoji": "👋" },
{ "name": "love", "emoji": "🥰" },
Expand All @@ -79,7 +79,7 @@
"settingId": "b28b1f41-10aa-4e37-a0c3-3bcca310cbe5"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/popping/b28b1f41-10aa-4e37-a0c3-3bcca310cbe5/sticker.png",
"url": "/sticker_5.png",
"emojis": [
{ "name": "cat", "emoji": "🐱" },
{ "name": "open mouth", "emoji": "😮" },
Expand All @@ -92,7 +92,7 @@
"settingId": "b28b1f41-10aa-4e37-a0c3-3bcca310cbe5"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/paws/b28b1f41-10aa-4e37-a0c3-3bcca310cbe5/sticker.png",
"url": "/sticker_4.png",
"emojis": [
{ "name": "paws", "emoji": "🐾" },
{ "name": "feet", "emoji": "👣" }
Expand All @@ -102,21 +102,21 @@
"settingId": "b28b1f41-10aa-4e37-a0c3-3bcca310cbe5"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/halloween/b28b1f41-10aa-4e37-a0c3-3bcca310cbe5/sticker.png",
"url": "/sticker_3.png",
"emojis": [{ "name": "eyes", "emoji": "👀" }],
"name": "Blank - Halloween",
"stickerId": "halloween",
"settingId": "b28b1f41-10aa-4e37-a0c3-3bcca310cbe5"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/heart/b28b1f41-10aa-4e37-a0c3-3bcca310cbe5/sticker.png",
"url": "/sticker_2.png",
"emojis": [{ "name": "heart", "emoji": "❤️" }],
"name": "Blank - Heart",
"stickerId": "heart",
"settingId": "b28b1f41-10aa-4e37-a0c3-3bcca310cbe5"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/hug/b28b1f41-10aa-4e37-a0c3-3bcca310cbe5/sticker.png",
"url": "/sticker_1.png",
"emojis": [
{ "name": "hugging", "emoji": "🫂" },
{ "name": "open hands", "emoji": "🤗" }
Expand All @@ -126,7 +126,7 @@
"settingId": "b28b1f41-10aa-4e37-a0c3-3bcca310cbe5"
},
{
"url": "https://tg-sticker-bot.vercel.app/api/dev/attribution/b28b1f41-10aa-4e37-a0c3-3bcca310cbe5/sticker.png",
"url": "/sticker_0.png",
"emojis": [
{ "name": "info", "emoji": "ℹ️" },
{ "name": "writing", "emoji": "✍️" }
Expand Down
Loading

0 comments on commit e0c84a9

Please sign in to comment.