Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
61 commits
Select commit Hold shift + click to select a range
50f2b4d
add: 로고 이미지 추가
rafa-e1 Jun 9, 2025
2fc912e
feat: 이미지 리소스 관리를 위한 열거형(MatzipImage) 구현
rafa-e1 Jun 9, 2025
8f7503b
add: 검색 아이콘 추가
rafa-e1 Jun 10, 2025
c31ff42
feat: 검색 아이콘 열거형 케이스 구현
rafa-e1 Jun 10, 2025
831be27
feat: 서브 텍스트 및 구분선 컬러 정의 추가
rafa-e1 Jun 10, 2025
e614e38
feat: UIView extension을 통해 addSubviews 메서드 구현
rafa-e1 Jun 10, 2025
fa3d4d1
feat: 커스텀 내비게이션 바 구현
rafa-e1 Jun 15, 2025
0032fb5
feat: HomeViewModel 추가 및 내비게이션 바 구성 로직 구현
rafa-e1 Jun 15, 2025
00e9089
feat: 뷰모델 프로토콜 기반 의존성 주입 및 커스텀 내비게이션 바 적용
rafa-e1 Jun 15, 2025
38c3f69
refactor: MainTab에서 HomeViewController에 뷰모델 의존성 주입 적용
rafa-e1 Jun 15, 2025
63f5354
refactor: super.setupStyles() 호출로 메인 배경색 설정 로직 반영
rafa-e1 Jun 15, 2025
b701295
add: Pretendard 폰트 추가
rafa-e1 Jun 15, 2025
bfd4c9b
feat: 커스텀 폰트 적용을 위한 UIFont 확장자 및 FontName enum 구현
rafa-e1 Jun 15, 2025
d9e51a9
feat: 공통 UICollectionView 기반 Base 뷰 클래스 구현 및 뷰 설정 메서드 추가
rafa-e1 Jun 15, 2025
09c0c1a
add: 아이콘 및 이미지 추가
rafa-e1 Jun 15, 2025
045d48a
add: 임시로 사용할 이미지 추가
rafa-e1 Jun 15, 2025
e78f880
feat: 추가된 아이콘 및 이미지 케이스 구현
rafa-e1 Jun 15, 2025
3b2e769
feat: 신규 컬러 4종 추가
rafa-e1 Jun 15, 2025
b3b93db
rename: UIView+의 폴더명을 UI로 수정
rafa-e1 Jun 16, 2025
1d2282b
feat: UIStackView에 configureStackView 유틸 함수 추가하여 반복 코드 제거
rafa-e1 Jun 17, 2025
2227e61
design: 커스텀 폰트 적용
rafa-e1 Jun 17, 2025
76e94c8
refactor: configureStackView 유틸 함수 적용
rafa-e1 Jun 17, 2025
29cc96a
feat: UIView 기반의 ReusableIdentifier 프로토콜 추가하여 identifier 자동화
rafa-e1 Jun 17, 2025
3b20ca7
feat: 공통 문구 관리를 위한 MatzipText enum 추가
rafa-e1 Jun 17, 2025
7094e79
feat: 투표 섹션 UI 구현
rafa-e1 Jun 17, 2025
5c33a02
add: 나머지 섹션 컬렉션 뷰 셀 파일 추가
rafa-e1 Jun 17, 2025
d6c510f
fix: 레이아웃 오류 해결
rafa-e1 Jun 17, 2025
173a998
feat: HomeSection enum에 헤더/푸터 타이틀 및 셀 identifier 추상화 추가
rafa-e1 Jun 17, 2025
631399b
feat: 홈 섹션 헤더 및 푸터 UI 구현
rafa-e1 Jun 17, 2025
3436ce0
refactor: 타입 추가
rafa-e1 Jun 17, 2025
57ce04d
refactor: ViewModel 폴더 생성 및 HomeViewModel 추가
rafa-e1 Jun 17, 2025
6c141f1
feat: 홈 섹션 레이아웃 추상화 구조 설계
rafa-e1 Jun 17, 2025
3bec860
feat: 공통 섹션 레이아웃 생성을 위한 SectionLayoutProviding 프로토콜 정의
rafa-e1 Jun 17, 2025
c839674
feat: 헤더 및 푸터 SupplementaryItem 생성을 위한 Factory 유틸 추가
rafa-e1 Jun 17, 2025
1e16730
feat: 공통 섹션 레이아웃 생성을 위한 DefaultSectionLayout 구현
rafa-e1 Jun 17, 2025
d882935
feat: 투표 섹션 전용 Compositional Layout 구성용 VoteSectionLayout 추가
rafa-e1 Jun 17, 2025
6427e85
feat: UICollectionView 섹션 구성 모듈화를 위한 SectionController 인터페이스 추가
rafa-e1 Jun 17, 2025
a2869c3
feat: 홈 섹션별 셀 및 SupplementaryView 관리를 위한 DefaultSectionController 구현
rafa-e1 Jun 17, 2025
68ff19a
feat: Header/Footer 없이 Vote 전용 셀만 구성하는 VoteSectionController 구현
rafa-e1 Jun 17, 2025
f234f83
feat: Home 화면의 섹션별 레이아웃 생성을 담당하는 HomeLayoutFactory 구현
rafa-e1 Jun 17, 2025
159e120
feat: 홈 투표 섹션 추가 및 컬렉션 뷰 UI 구현
rafa-e1 Jun 17, 2025
0680c59
chore: Xcode 프로젝트 메타데이터 업데이트 (LastUpgradeCheck 1640으로 변경)
rafa-e1 Jun 17, 2025
f540a80
refactor: Supplementary 폴더를 Section 폴더 내부로 이동
rafa-e1 Jun 17, 2025
3ef492e
refactor: SectionLayout으로 폴더명 수정
rafa-e1 Jun 17, 2025
7f54eff
rename: 더 직관적인 이름으로 파일명 및 enum 수정
rafa-e1 Jun 29, 2025
5faf5e3
feat: 홈 화면 섹션별 셀 configure 메서드 기본 구현 추가
rafa-e1 Jun 29, 2025
9a0d3d2
refactor: 하드 코딩된 데이터 제거 및 configureVoteButton 함수 옵셔널 이미지 지원하도록 개선
rafa-e1 Jun 29, 2025
8d8432e
feat: 홈 화면 셀 뷰모델 구현 (추천, 숨은맛집, 주변랭킹, 투표)
rafa-e1 Jun 29, 2025
f28656c
rename: Recommendation을 PersonalRecommendation으로 변경하여 개인화 의미를 명확히 함
rafa-e1 Jun 29, 2025
1a39588
feat: 도메인 모델 및 추천 섹션 타입 enum 구현
rafa-e1 Jun 29, 2025
b15ea5e
remove: 미사용 코드 제거
rafa-e1 Jun 29, 2025
500e459
feat: 홈 섹션별 SectionController 구현 및 ViewModel 연결
rafa-e1 Jun 29, 2025
1997d2d
rename: 각 프로토콜의 역할과 의도를 명확히 표현하도록 이름 변경
rafa-e1 Jun 29, 2025
d074ef5
refactor: 폴더 구조 재정비
rafa-e1 Jun 29, 2025
8eab445
feat: HomeSectionType에 섹션 타입 추가 및 레이아웃 메서드 구현
rafa-e1 Jun 29, 2025
e7d3f57
feat: 각 섹션 더미 데이터 구성 로직 추가
rafa-e1 Jun 29, 2025
41b4bd1
feat: HeaderFooterDisplayable 프로토콜 정의하여 섹션 헤더, 푸터 지원
rafa-e1 Jun 29, 2025
0389c1f
feat: 섹션별 레이아웃 분기 처리
rafa-e1 Jun 29, 2025
b798563
refactor: 간결하고 직관적인 이름으로 수정 및 적용
rafa-e1 Jun 29, 2025
98c7ca2
refactor: HomeViewModel 프로토콜 제거 및 sections 변수명 개선
rafa-e1 Jun 29, 2025
1d1e416
refactor: 미사용 코드 제거 및 변경된 네이밍 적용
rafa-e1 Jun 29, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion MatzipBook/MatzipBook.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@
attributes = {
BuildIndependentTargetsInParallel = 1;
LastSwiftUpdateCheck = 1620;
LastUpgradeCheck = 1620;
LastUpgradeCheck = 1640;
TargetAttributes = {
05E5F5B62D956A6A00F0CB97 = {
CreatedOnToolsVersion = 16.2;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
//
// ReusableIdentifier+.swift
// MatzipBook
//
// Created by 심범수 on 6/16/25.
//

import UIKit

protocol ReusableIdentifier: AnyObject {}

extension ReusableIdentifier where Self: UIView {

static var identifier: String {
return String(describing: self)
}
}

extension UICollectionReusableView: ReusableIdentifier {}
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,6 @@ enum MatzipIcon: String {
case icLocationUnselected = "ic_location_unselected"
case icPersonSelected = "ic_person_selected"
case icPersonUnselected = "ic_person_unselected"
case icSearch = "ic_search"
case icClock = "ic_clock"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
//
// MatzipImage.swift
// MatzipBook
//
// Created by 심범수 on 6/9/25.
//

import Foundation

enum MatzipImage: String {
case imgLogo = "img_logo"
case imgBubble = "img_bubble"
case imgVS = "img_vs"
}
Comment on lines +10 to +14
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

사용되는 image, Text 들을 enum으로 관리해서 좋네요!!

혹시 따로 궁금한점인데 img_logo나 ic_clock등 snake case를 쓰신 이유가 궁금합니다!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Asset Catalog에서는 이름 구분할 때 대소문자를 구분하지 않아서 이미지 등록할 때 스네이크 케이스로 등록하는 것이 충돌 가능성을 방지하는걸로 알고 있습니다!

Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
//
// MatzipText.swift
// MatzipBook
//
// Created by 심범수 on 6/17/25.
//

import Foundation

enum MatzipText {
enum Vote {
static let title: String = "당신의 선택은?"
static let subtitle: String = "오늘 당신의 맛집을 투표해주세요!"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,10 @@ extension UIColor {

static let mainBackgroundColor: UIColor = UIColor(hex: "FAFAFA")
static let shadowColor: UIColor = UIColor(hex: "000000", alpha: 0.13)
static let sub1: UIColor = UIColor(hex: "787878")
static let sub2: UIColor = UIColor(hex: "A8A8A8")
static let separatorColor: UIColor = UIColor(hex: "D9D9D9")
static let mainLight2: UIColor = UIColor(hex: "FFB273")
static let boxColor: UIColor = UIColor(hex: "F0F0F0")
static let mainOrange: UIColor = UIColor(hex: "FF8400")
}
20 changes: 20 additions & 0 deletions MatzipBook/MatzipBook/Core/DesignSystem/Foundation/UIFont+.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
//
// UIFont+.swift
// MatzipBook
//
// Created by 심범수 on 6/15/25.
//

import UIKit

enum FontName: String {
case bold = "Pretendard-Bold"
case regular = "Pretendard-Regular"
}

extension UIFont {

static func applyFont(_ name: FontName, ofSize size: CGFloat) -> UIFont {
return UIFont(name: name.rawValue, size: size) ?? .systemFont(ofSize: size)
}
}
Comment on lines +15 to +20
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

오 폰트를 이렇게 쓰는 방법도 있군요
저는 폰트를 쓸때 SwiftUI긴 하지만

static var pretendardBold14: Font { .pretend(type: .bold, size: 14) }
static var pretendardBold16: Font { .pretend(type: .bold, size: 16) }

이런식으로 썻는데 범수님 같이 쓰는게 더 확장성이 좋아보이네요!!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

말씀해주신 방식도 충분히 좋은 접근이고 상황에 따라 더 적합할 수도 있다고 생각합니다!
결국 코드에는 정답은 없고 프로젝트의 성격과 팀의 방향성에 따라 유연하게 선택하는게 가장 중요하다고 생각해요

Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"images" : [
{
"filename" : "ic_clock.svg",
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
},
"properties" : {
"preserves-vector-representation" : true
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"images" : [
{
"filename" : "ic_search.svg",
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
},
"properties" : {
"preserves-vector-representation" : true
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"images" : [
{
"filename" : "img_bubble.svg",
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
},
"properties" : {
"preserves-vector-representation" : true
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"images" : [
{
"filename" : "img_dummy0.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "img_dummy0@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "img_dummy0@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"images" : [
{
"filename" : "img_dummy1.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "img_dummy1@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "img_dummy1@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"images" : [
{
"filename" : "img_logo.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "img_logo@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "img_logo@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"images" : [
{
"filename" : "img_vs.svg",
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
},
"properties" : {
"preserves-vector-representation" : true
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
23 changes: 23 additions & 0 deletions MatzipBook/MatzipBook/Core/UI/Extension/UIStackView+.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
//
// UIStackView+.swift
// MatzipBook
//
// Created by 심범수 on 6/16/25.
//

import UIKit

extension UIStackView {

func configureStackView(
axis: NSLayoutConstraint.Axis = .horizontal,
alignment: UIStackView.Alignment = .fill,
distribution: UIStackView.Distribution = .fillEqually,
spacing: CGFloat = 0
) {
self.axis = axis
self.alignment = alignment
self.distribution = distribution
self.spacing = spacing
}
}
15 changes: 15 additions & 0 deletions MatzipBook/MatzipBook/Core/UI/Extension/UIView+.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
//
// UIView+.swift
// MatzipBook
//
// Created by 심범수 on 6/10/25.
//

import UIKit

extension UIView {

func addSubviews(_ views: UIView...) {
views.forEach { addSubview($0) }
}
}
Comment on lines +10 to +15
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이부분은 addSubview를 여러번 말고 한번에 다 추가하는 방식이네요!! 배워갑니다!! 🙏

...으로 list가 아닌 방식으로 하는 방식도 좋네요!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

감사합니다! 🙏
개인적으로 ... 을 사용하면 줄바꿈했을 때 더 깔끔한 것 같더라고요:)

5 changes: 5 additions & 0 deletions MatzipBook/MatzipBook/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>UIAppFonts</key>
<array>
<string>Pretendard-Bold.otf</string>
<string>Pretendard-Regular.otf</string>
</array>
<key>UIApplicationSceneManifest</key>
<dict>
<key>UIApplicationSupportsMultipleScenes</key>
Expand Down
Loading