Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Week2] (#3) 2주차 과제 #4

Open
wants to merge 28 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
95887b5
initial commit
mnbvcxzyj Oct 10, 2024
1e2cdf9
feat: 퀴즈 이미지 추가 및 퀴즈 기능
mnbvcxzyj Oct 11, 2024
84fc95d
feat: 퀴즈 이미지 추가 및 정답, 오답 확인 기능 추가
mnbvcxzyj Oct 11, 2024
4214fd5
feat: button에 isHidden 속성 추가
mnbvcxzyj Oct 11, 2024
4bef22f
refactor: 함수 분리, 변수명 수정, addSubviews extension 추가
mnbvcxzyj Oct 13, 2024
5e6331a
remove: seminar directory
mnbvcxzyj Oct 13, 2024
cc6804f
Merge .gitignore file
mnbvcxzyj Oct 18, 2024
8238a8b
refactor: 파일명 및 폴더구조 변경
mnbvcxzyj Oct 18, 2024
a71249a
feat: 첫번째 섹션 UI 구현(App이름, 아이콘, 열기 공유 버튼)
mnbvcxzyj Oct 19, 2024
2d9aadc
feat: 두번째 섹션 UI 구현(평가, 수상, 연령정보)
mnbvcxzyj Oct 19, 2024
d716605
feat: 세번째 섹션 UI 구현(뉴스, 버전기록)
mnbvcxzyj Oct 19, 2024
7e504b7
feat: 네번째 섹션 UI 구현(미리보기 이미지, 기기 아이콘)
mnbvcxzyj Oct 20, 2024
33544d0
feat: 다섯번째 섹션 UI 구현(앱 설명, 더보기, 개발자 정보)
mnbvcxzyj Oct 20, 2024
81f7880
feat: 탭하여 평가, 사용자 리뷰 UI 구현
mnbvcxzyj Oct 21, 2024
5d4def7
feat: 개발자 답변 UI 구현
mnbvcxzyj Oct 21, 2024
823c28e
feat: 리뷰작성, 앱 지원 버튼 UI 구현
mnbvcxzyj Oct 21, 2024
fd42bbe
feat: 더보기 버튼 추가
mnbvcxzyj Oct 22, 2024
bcf6e55
feat: 네비게이션 바 세팅
mnbvcxzyj Oct 22, 2024
bd2c9b4
design: UI 간격 수정
mnbvcxzyj Oct 22, 2024
648a224
feat: 버전 기록, 평가 및 리뷰 모두보기 페이지 이동
mnbvcxzyj Oct 22, 2024
2eb8b7d
design: 네비게이션바 스타일 설정 함수 변경
mnbvcxzyj Oct 22, 2024
e7bfc28
feat: 앱 설명 더보기 구현
mnbvcxzyj Oct 22, 2024
b13a749
refactor: 뷰 파일 생성
mnbvcxzyj Oct 24, 2024
3bdaaf0
fix: 제약조건 수정
mnbvcxzyj Oct 24, 2024
5b41708
feat: 버전 기록, 평가 및 리뷰 모두보기 페이지 이동 연결 및 코드 정리
mnbvcxzyj Oct 24, 2024
c5ad5f8
refactor: 주석 작성
mnbvcxzyj Oct 25, 2024
9ddd722
refactor: 제약조건 수정
mnbvcxzyj Oct 25, 2024
560c007
remove: 사용하지 않는 파일 및 이미지 삭제
mnbvcxzyj Oct 25, 2024
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
738 changes: 738 additions & 0 deletions AND-SOPT-iOS/AND-SOPT-iOS.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>SchemeUserState</key>
<dict>
<key>AND-SOPT-iOS.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
</dict>
</dict>
</dict>
</plist>
35 changes: 35 additions & 0 deletions AND-SOPT-iOS/AND-SOPT-iOS/Application/AppDelegate.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
//
// AppDelegate.swift
// AND-SOPT-iOS
//
// Created by 김예지 on 10/10/24.
//

import UIKit

@main
class AppDelegate: UIResponder, UIApplicationDelegate {


func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
// Override point for customization after application launch.
return true
}

// MARK: UISceneSession Lifecycle

func application(_ application: UIApplication, configurationForConnecting connectingSceneSession: UISceneSession, options: UIScene.ConnectionOptions) -> UISceneConfiguration {
// Called when a new scene session is being created.
// Use this method to select a configuration to create the new scene with.
return UISceneConfiguration(name: "Default Configuration", sessionRole: connectingSceneSession.role)
}

func application(_ application: UIApplication, didDiscardSceneSessions sceneSessions: Set<UISceneSession>) {
// Called when the user discards a scene session.
// If any sessions were discarded while the application was not running, this will be called shortly after application:didFinishLaunchingWithOptions.
// Use this method to release any resources that were specific to the discarded scenes, as they will not return.
}


}

47 changes: 47 additions & 0 deletions AND-SOPT-iOS/AND-SOPT-iOS/Application/SceneDelegate.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@

import UIKit

class SceneDelegate: UIResponder, UIWindowSceneDelegate {

var window: UIWindow?


func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) {
guard let windowScene = (scene as? UIWindowScene) else { return }
self.window = UIWindow(windowScene: windowScene)
let navigationController = UINavigationController(rootViewController: AppStoreTossMainViewController())
self.window?.rootViewController = navigationController
self.window?.makeKeyAndVisible()
}

func sceneDidDisconnect(_ scene: UIScene) {
// Called as the scene is being released by the system.
// This occurs shortly after the scene enters the background, or when its session is discarded.
// Release any resources associated with this scene that can be re-created the next time the scene connects.
// The scene may re-connect later, as its session was not necessarily discarded (see `application:didDiscardSceneSessions` instead).
}

func sceneDidBecomeActive(_ scene: UIScene) {
// Called when the scene has moved from an inactive state to an active state.
// Use this method to restart any tasks that were paused (or not yet started) when the scene was inactive.
}

func sceneWillResignActive(_ scene: UIScene) {
// Called when the scene will move from an active state to an inactive state.
// This may occur due to temporary interruptions (ex. an incoming phone call).
}

func sceneWillEnterForeground(_ scene: UIScene) {
// Called as the scene transitions from the background to the foreground.
// Use this method to undo the changes made on entering the background.
}

func sceneDidEnterBackground(_ scene: UIScene) {
// Called as the scene transitions from the foreground to the background.
// Use this method to save data, release shared resources, and store enough scene-specific state information
// to restore the scene back to its current state.
}


}

Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"colors" : [
{
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"images" : [
{
"idiom" : "universal",
"platform" : "ios",
"size" : "1024x1024"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
6 changes: 6 additions & 0 deletions AND-SOPT-iOS/AND-SOPT-iOS/Assets.xcassets/Contents.json
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,21 @@
{
"images" : [
{
"filename" : "donut.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"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.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "pipo.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"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.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "pogen.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"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.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "preview.jpg",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"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.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "스크린샷 2024-10-25 오후 7.00.58.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"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.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "toss.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"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.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "waffle.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"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.
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
//
// AnswerCountViewController.swift
// AND-SOPT-iOS
//
// Created by 김예지 on 10/10/24.
//

import UIKit

class AnswerCountViewController: UIViewController {

private let answerCountLabel: UILabel = {
let label = UILabel()
label.font = .systemFont(ofSize: 20, weight: .semibold)
return label
}()

private lazy var backButton: UIButton = {
let button = UIButton()
button.setTitle("이전 화면으로", for: .normal)
button.backgroundColor = .tintColor
button.setTitleColor(.white, for: .normal)
button.addTarget(self, action: #selector(backButtonTapped), for: .touchUpInside)
return button
}()

private var receivedCount: Int?

override func viewDidLoad() {
super.viewDidLoad()
setStyle()
setUI()
setLayout()
}

private func setStyle() {
self.view.backgroundColor = .lightGray
}

private func setUI() {
view.addSubviews(answerCountLabel, backButton)
}

private func setLayout() {
NSLayoutConstraint.activate(
[
answerCountLabel.topAnchor.constraint(
equalTo: view.safeAreaLayoutGuide.topAnchor,
constant: 50
),
answerCountLabel.centerXAnchor.constraint(equalTo: view.centerXAnchor),

backButton.topAnchor.constraint(
equalTo: answerCountLabel.bottomAnchor,
constant: 20
),
backButton.centerXAnchor.constraint(equalTo: view.centerXAnchor),
backButton.heightAnchor.constraint(equalToConstant: 44),
backButton.widthAnchor.constraint(equalToConstant: 300),
]
)
}

func updateUI() {
answerCountLabel.text = "정답 개수 : \(receivedCount ?? 0)"
}

func dataBind(count: Int) {
self.receivedCount = count
updateUI()
}

@objc func backButtonTapped() {
if self.navigationController == nil {
self.dismiss(animated: true)
} else {
self.navigationController?.popViewController(animated: true)
}
}
}
Loading