Skip to content

Commit 726967c

Browse files
authored
Merge pull request #32 from YAPP-Github/feat/#27-검색API연결
Feat/#27 검색api연결
2 parents d0ec5e2 + 1d42a4c commit 726967c

59 files changed

Lines changed: 1395 additions & 130 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Plugins/EnvPlugin/ProjectDescriptionHelpers/InfoPlist.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ public extension Project {
3232
"NSAllowsArbitraryLoads": .boolean(true)
3333
]),
3434
"ITSAppUsesNonExemptEncryption": .boolean(false),
35-
"BASE_URL": .string("$(BASE_URL)")
35+
"BASE_URL": .string("$(BASE_URL)"),
36+
"X_API_KEY": .string("$(X_API_KEY)")
3637
]
3738

3839
static let demoInfoPlist: [String: Plist.Value] = [
25.1 KB
Loading
Binary file not shown.

Projects/App/Resources/Assets.xcassets/AppIcon.appiconset/Contents.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"images" : [
33
{
4-
"filename" : "AppIcon~ios-marketing.png",
4+
"filename" : "AppIcon_Spring_IOS_1024.png",
55
"idiom" : "universal",
66
"platform" : "ios",
77
"size" : "1024x1024"
6.04 KB
Loading
Lines changed: 24 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
1-
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2-
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="13142" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="01J-lp-oVM">
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="24506" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="01J-lp-oVM">
3+
<device id="retina6_12" orientation="portrait" appearance="light"/>
34
<dependencies>
4-
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="12042"/>
5-
<capability name="Constraints with non-1.0 multipliers" minToolsVersion="5.1"/>
5+
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="24504"/>
6+
<capability name="Named colors" minToolsVersion="9.0"/>
67
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
78
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
89
</dependencies>
@@ -12,37 +13,35 @@
1213
<objects>
1314
<viewController id="01J-lp-oVM" sceneMemberID="viewController">
1415
<view key="view" contentMode="scaleToFill" id="Ze5-6b-2t3">
15-
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
16+
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
1617
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
1718
<subviews>
18-
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Copyright © 2026 NDGL-iOS. All rights reserved." textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" minimumFontSize="9" translatesAutoresizingMaskIntoConstraints="NO" id="obG-Y5-kRd">
19-
<rect key="frame" x="0.0" y="626.5" width="375" height="20.5"/>
20-
<fontDescription key="fontDescription" type="system" pointSize="17"/>
21-
<color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
22-
<nil key="highlightedColor"/>
23-
</label>
24-
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="App" textAlignment="center" lineBreakMode="middleTruncation" baselineAdjustment="alignBaselines" minimumFontSize="18" translatesAutoresizingMaskIntoConstraints="NO" id="GJd-Yh-RWb">
25-
<rect key="frame" x="0.0" y="202" width="375" height="43"/>
26-
<fontDescription key="fontDescription" type="boldSystem" pointSize="36"/>
27-
<color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
28-
<nil key="highlightedColor"/>
29-
</label>
19+
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="LaunchLogo.png" translatesAutoresizingMaskIntoConstraints="NO" id="cNo-yc-A0v">
20+
<rect key="frame" x="160.66666666666666" y="397" width="72" height="108"/>
21+
<color key="backgroundColor" name="green300"/>
22+
<constraints>
23+
<constraint firstAttribute="height" constant="108" id="5e9-NY-PMN"/>
24+
<constraint firstAttribute="width" constant="72" id="y5A-m1-kTT"/>
25+
</constraints>
26+
</imageView>
3027
</subviews>
31-
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
28+
<viewLayoutGuide key="safeArea" id="Bcu-3y-fUS"/>
29+
<color key="backgroundColor" name="green300"/>
3230
<constraints>
33-
<constraint firstItem="Bcu-3y-fUS" firstAttribute="centerX" secondItem="obG-Y5-kRd" secondAttribute="centerX" id="5cz-MP-9tL"/>
34-
<constraint firstItem="Bcu-3y-fUS" firstAttribute="centerX" secondItem="GJd-Yh-RWb" secondAttribute="centerX" id="Q3B-4B-g5h"/>
35-
<constraint firstItem="obG-Y5-kRd" firstAttribute="leading" secondItem="Bcu-3y-fUS" secondAttribute="leading" constant="20" symbolic="YES" id="SfN-ll-jLj"/>
36-
<constraint firstAttribute="bottom" secondItem="obG-Y5-kRd" secondAttribute="bottom" constant="20" id="Y44-ml-fuU"/>
37-
<constraint firstItem="GJd-Yh-RWb" firstAttribute="centerY" secondItem="Ze5-6b-2t3" secondAttribute="bottom" multiplier="1/3" constant="1" id="moa-c2-u7t"/>
38-
<constraint firstItem="GJd-Yh-RWb" firstAttribute="leading" secondItem="Bcu-3y-fUS" secondAttribute="leading" constant="20" symbolic="YES" id="x7j-FC-K8j"/>
31+
<constraint firstItem="cNo-yc-A0v" firstAttribute="centerY" secondItem="Bcu-3y-fUS" secondAttribute="centerY" id="lzf-rq-KXE"/>
32+
<constraint firstItem="cNo-yc-A0v" firstAttribute="centerX" secondItem="Bcu-3y-fUS" secondAttribute="centerX" id="tjh-yU-7rh"/>
3933
</constraints>
40-
<viewLayoutGuide key="safeArea" id="Bcu-3y-fUS"/>
4134
</view>
4235
</viewController>
4336
<placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/>
4437
</objects>
4538
<point key="canvasLocation" x="53" y="375"/>
4639
</scene>
4740
</scenes>
41+
<resources>
42+
<image name="LaunchLogo.png" width="72" height="108"/>
43+
<namedColor name="green300">
44+
<color red="0.45098042488098145" green="0.81568628549575806" blue="0.54509806632995605" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
45+
</namedColor>
46+
</resources>
4847
</document>

Projects/App/Sources/Application/AppComponent.swift

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,12 @@ final class AppComponent: Component<EmptyDependency>, RootDependency {
6060
)
6161
}
6262
}
63+
64+
var templateSearchUsecase: TemplatesSearchUsecaseProtocol {
65+
shared {
66+
TemplatesSearchUsecase(travelTemplateRepository: travelTemplateRepository)
67+
}
68+
}
6369

6470
var authRepository: AuthRepositoryInterface {
6571
shared { makeAuthRepository() }
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
//
2+
// UIViewController+.swift
3+
// Core
4+
//
5+
// Created by 최안용 on 2/18/26.
6+
// Copyright © 2026 NDGL-iOS. All rights reserved.
7+
//
8+
9+
import UIKit
10+
11+
public extension UIViewController {
12+
func hideKeyboard() {
13+
let tap = UITapGestureRecognizer(target: self, action: #selector(UIViewController.dismissKeyboard))
14+
tap.cancelsTouchesInView = false
15+
view.addGestureRecognizer(tap)
16+
}
17+
18+
@objc
19+
func dismissKeyboard() {
20+
view.endEditing(true)
21+
}
22+
}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
//
2+
// URLHelper.swift
3+
// Core
4+
//
5+
// Created by 최안용 on 2/20/26.
6+
// Copyright © 2026 NDGL-iOS. All rights reserved.
7+
//
8+
9+
import UIKit
10+
11+
public struct URLHelper {
12+
public static func openURL(_ urlString: String) {
13+
guard let url = URL(string: urlString) else { return }
14+
UIApplication.shared.open(url)
15+
}
16+
}

Projects/Data/Sources/Repository/TravelTemplate /TravelTemplateRepository.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,9 @@ public final class TravelTemplateRepository: TravelTemplateRepositoryInterface {
3434
}
3535
}
3636

37-
public func searchTemplate() async throws -> Int {
37+
public func searchTemplate(keyword: String, page: Int?, size: Int?) async throws -> [TripInfo] {
3838
do {
39-
return try await service.searchTemplate()
39+
return try await service.searchTemplate(keyword: keyword, page: page, size: size).toDomain()
4040
} catch {
4141
throw error.toNDGLError()
4242
}

0 commit comments

Comments
 (0)