From 67468c778adb0c083203f2dc9acfe99c956a5647 Mon Sep 17 00:00:00 2001 From: neon443 <69979447+neon443@users.noreply.github.com> Date: Wed, 15 Oct 2025 23:17:56 +0100 Subject: [PATCH] added slackresponse, emojihoarder (empty rn), basic project structure --- StickerSlack.xcodeproj/project.pbxproj | 79 ++++++++++++++----- StickerSlack/Emoji/SlackResponse.swift | 29 +++++++ StickerSlack/EmojiHoarder.swift | 15 ++++ .../AccentColor.colorset/Contents.json | 0 .../AppIcon.appiconset/Contents.json | 0 .../Assets.xcassets/Contents.json | 0 StickerSlack/{ => Views}/ContentView.swift | 0 7 files changed, 105 insertions(+), 18 deletions(-) create mode 100644 StickerSlack/Emoji/SlackResponse.swift create mode 100644 StickerSlack/EmojiHoarder.swift rename StickerSlack/{ => Resources}/Assets.xcassets/AccentColor.colorset/Contents.json (100%) rename StickerSlack/{ => Resources}/Assets.xcassets/AppIcon.appiconset/Contents.json (100%) rename StickerSlack/{ => Resources}/Assets.xcassets/Contents.json (100%) rename StickerSlack/{ => Views}/ContentView.swift (100%) diff --git a/StickerSlack.xcodeproj/project.pbxproj b/StickerSlack.xcodeproj/project.pbxproj index b197985..cd23306 100644 --- a/StickerSlack.xcodeproj/project.pbxproj +++ b/StickerSlack.xcodeproj/project.pbxproj @@ -6,18 +6,23 @@ objectVersion = 77; objects = { +/* Begin PBXBuildFile section */ + A949B1F32EA04E8200215164 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = A949B1EF2EA04E8200215164 /* Assets.xcassets */; }; + A949B1F42EA04E8200215164 /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = A949B1F02EA04E8200215164 /* ContentView.swift */; }; + A949B1F52EA04E8200215164 /* StickerSlackApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = A949B1F12EA04E8200215164 /* StickerSlackApp.swift */; }; + A949B1F82EA04F2300215164 /* EmojiHoarder.swift in Sources */ = {isa = PBXBuildFile; fileRef = A949B1F72EA04F2300215164 /* EmojiHoarder.swift */; }; + A949B1FB2EA0518800215164 /* SlackResponse.swift in Sources */ = {isa = PBXBuildFile; fileRef = A949B1FA2EA0518800215164 /* SlackResponse.swift */; }; +/* End PBXBuildFile section */ + /* Begin PBXFileReference section */ A949B1DF2EA04C0B00215164 /* StickerSlack.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = StickerSlack.app; sourceTree = BUILT_PRODUCTS_DIR; }; + A949B1EF2EA04E8200215164 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + A949B1F02EA04E8200215164 /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = ""; }; + A949B1F12EA04E8200215164 /* StickerSlackApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StickerSlackApp.swift; sourceTree = ""; }; + A949B1F72EA04F2300215164 /* EmojiHoarder.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EmojiHoarder.swift; sourceTree = ""; }; + A949B1FA2EA0518800215164 /* SlackResponse.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SlackResponse.swift; sourceTree = ""; }; /* End PBXFileReference section */ -/* Begin PBXFileSystemSynchronizedRootGroup section */ - A949B1E12EA04C0B00215164 /* StickerSlack */ = { - isa = PBXFileSystemSynchronizedRootGroup; - path = StickerSlack; - sourceTree = ""; - }; -/* End PBXFileSystemSynchronizedRootGroup section */ - /* Begin PBXFrameworksBuildPhase section */ A949B1DC2EA04C0B00215164 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; @@ -32,7 +37,7 @@ A949B1D62EA04C0B00215164 = { isa = PBXGroup; children = ( - A949B1E12EA04C0B00215164 /* StickerSlack */, + A949B1F22EA04E8200215164 /* StickerSlack */, A949B1E02EA04C0B00215164 /* Products */, ); sourceTree = ""; @@ -45,6 +50,42 @@ name = Products; sourceTree = ""; }; + A949B1EE2EA04E8200215164 /* Views */ = { + isa = PBXGroup; + children = ( + A949B1F02EA04E8200215164 /* ContentView.swift */, + ); + path = Views; + sourceTree = ""; + }; + A949B1F22EA04E8200215164 /* StickerSlack */ = { + isa = PBXGroup; + children = ( + A949B1F92EA0517800215164 /* Emoji */, + A949B1F12EA04E8200215164 /* StickerSlackApp.swift */, + A949B1F72EA04F2300215164 /* EmojiHoarder.swift */, + A949B1EE2EA04E8200215164 /* Views */, + A949B1F62EA04E8C00215164 /* Resources */, + ); + path = StickerSlack; + sourceTree = ""; + }; + A949B1F62EA04E8C00215164 /* Resources */ = { + isa = PBXGroup; + children = ( + A949B1EF2EA04E8200215164 /* Assets.xcassets */, + ); + path = Resources; + sourceTree = ""; + }; + A949B1F92EA0517800215164 /* Emoji */ = { + isa = PBXGroup; + children = ( + A949B1FA2EA0518800215164 /* SlackResponse.swift */, + ); + path = Emoji; + sourceTree = ""; + }; /* End PBXGroup section */ /* Begin PBXNativeTarget section */ @@ -60,9 +101,6 @@ ); dependencies = ( ); - fileSystemSynchronizedGroups = ( - A949B1E12EA04C0B00215164 /* StickerSlack */, - ); name = StickerSlack; packageProductDependencies = ( ); @@ -109,6 +147,7 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( + A949B1F32EA04E8200215164 /* Assets.xcassets in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -119,6 +158,10 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( + A949B1F42EA04E8200215164 /* ContentView.swift in Sources */, + A949B1F52EA04E8200215164 /* StickerSlackApp.swift in Sources */, + A949B1FB2EA0518800215164 /* SlackResponse.swift in Sources */, + A949B1F82EA04F2300215164 /* EmojiHoarder.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -264,10 +307,10 @@ "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - IPHONEOS_DEPLOYMENT_TARGET = 26.0; + IPHONEOS_DEPLOYMENT_TARGET = 16; LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 15.7; + MACOSX_DEPLOYMENT_TARGET = 13; MARKETING_VERSION = 1.0; PRODUCT_BUNDLE_IDENTIFIER = com.neon443.StickerSlack; PRODUCT_NAME = "$(TARGET_NAME)"; @@ -281,7 +324,7 @@ SWIFT_UPCOMING_FEATURE_MEMBER_IMPORT_VISIBILITY = YES; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2,7"; - XROS_DEPLOYMENT_TARGET = 26.0; + XROS_DEPLOYMENT_TARGET = 1; }; name = Debug; }; @@ -308,10 +351,10 @@ "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - IPHONEOS_DEPLOYMENT_TARGET = 26.0; + IPHONEOS_DEPLOYMENT_TARGET = 16; LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 15.7; + MACOSX_DEPLOYMENT_TARGET = 13; MARKETING_VERSION = 1.0; PRODUCT_BUNDLE_IDENTIFIER = com.neon443.StickerSlack; PRODUCT_NAME = "$(TARGET_NAME)"; @@ -325,7 +368,7 @@ SWIFT_UPCOMING_FEATURE_MEMBER_IMPORT_VISIBILITY = YES; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2,7"; - XROS_DEPLOYMENT_TARGET = 26.0; + XROS_DEPLOYMENT_TARGET = 1; }; name = Release; }; diff --git a/StickerSlack/Emoji/SlackResponse.swift b/StickerSlack/Emoji/SlackResponse.swift new file mode 100644 index 0000000..1989b98 --- /dev/null +++ b/StickerSlack/Emoji/SlackResponse.swift @@ -0,0 +1,29 @@ +// +// SlackResponse.swift +// StickerSlack +// +// Created by neon443 on 15/10/2025. +// + +import Foundation + +struct SlackResponse: Codable { + var ok: Bool + var emoji: [String:String] + + func toEmojiResponse() -> [SlackEmojiResponse] { + return emoji.map { + SlackEmojiResponse(name: $0.key, url: $0.value) + } + } +} + +struct SlackEmojiResponse: Codable { + var name: String + var url: String + + init(name: String, url: String) { + self.name = name + self.url = url + } +} diff --git a/StickerSlack/EmojiHoarder.swift b/StickerSlack/EmojiHoarder.swift new file mode 100644 index 0000000..3cca52a --- /dev/null +++ b/StickerSlack/EmojiHoarder.swift @@ -0,0 +1,15 @@ +// +// EmojiHoarder.swift +// StickerSlack +// +// Created by neon443 on 15/10/2025. +// + +import Foundation +import SwiftUI +import Combine + +class EmojiHoarder: ObservableObject { + private let endpoint: URL = URL(string: "https://slack.com/api/emoji.list")! + @Published var kys = "" +} diff --git a/StickerSlack/Assets.xcassets/AccentColor.colorset/Contents.json b/StickerSlack/Resources/Assets.xcassets/AccentColor.colorset/Contents.json similarity index 100% rename from StickerSlack/Assets.xcassets/AccentColor.colorset/Contents.json rename to StickerSlack/Resources/Assets.xcassets/AccentColor.colorset/Contents.json diff --git a/StickerSlack/Assets.xcassets/AppIcon.appiconset/Contents.json b/StickerSlack/Resources/Assets.xcassets/AppIcon.appiconset/Contents.json similarity index 100% rename from StickerSlack/Assets.xcassets/AppIcon.appiconset/Contents.json rename to StickerSlack/Resources/Assets.xcassets/AppIcon.appiconset/Contents.json diff --git a/StickerSlack/Assets.xcassets/Contents.json b/StickerSlack/Resources/Assets.xcassets/Contents.json similarity index 100% rename from StickerSlack/Assets.xcassets/Contents.json rename to StickerSlack/Resources/Assets.xcassets/Contents.json diff --git a/StickerSlack/ContentView.swift b/StickerSlack/Views/ContentView.swift similarity index 100% rename from StickerSlack/ContentView.swift rename to StickerSlack/Views/ContentView.swift