Skip to content

[#258]만든 사람들 페이지 수정 #277

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

Merged
merged 4 commits into from
May 25, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
33 changes: 28 additions & 5 deletions EATSSU/App/Sources/Presentation/MyPage/View/CreatorsView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,24 @@ import SnapKit
/// "만든 사람들"을 담고 있는 View 입니다.
class CreatorsView: BaseUIView {
// MARK: - UI Components

let scrollView: UIScrollView = {
let scrollView = UIScrollView()
scrollView.showsVerticalScrollIndicator = false
scrollView.contentInsetAdjustmentBehavior = .never
return scrollView
}()

let contentView: UIView = {
let view = UIView()
view.backgroundColor = .clear
return view
}()

private let creatorsImageView: UIImageView = {
let imageView = UIImageView()
imageView.image = EATSSUDesignAsset.Images.creators.image
imageView.contentMode = .scaleAspectFit
imageView.snp.makeConstraints { make in
make.width.equalTo(342)
make.height.equalTo(689)
}
return imageView
}()

Expand All @@ -40,12 +49,26 @@ class CreatorsView: BaseUIView {
// MARK: - Methods

override func configureUI() {
addSubview(creatorsImageView)
addSubview(scrollView)
scrollView.addSubview(contentView)
contentView.addSubview(creatorsImageView)
}

override func setLayout() {
scrollView.snp.makeConstraints { make in
make.edges.equalToSuperview()
}

contentView.snp.makeConstraints { make in
make.edges.equalTo(scrollView)
make.width.equalToSuperview()
make.bottom.equalTo(creatorsImageView.snp.bottom).offset(52)
}

creatorsImageView.snp.makeConstraints { make in
make.center.equalToSuperview()
make.width.equalTo(276)
make.height.equalTo(1770)
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ import UIKit
// External Module
import SnapKit

import EATSSUDesign

class CreatorViewController: BaseViewController {
// MARK: - Properties

Expand All @@ -31,9 +33,9 @@ class CreatorViewController: BaseViewController {

override func setLayout() {
creatorsView.snp.makeConstraints { make in
make.top.equalToSuperview().inset(103)
make.leading.trailing.equalToSuperview().inset(24)
make.bottom.equalToSuperview().inset(52)
make.top.equalToSuperview().inset(66)
make.horizontalEdges.equalToSuperview().inset(24)
make.bottom.equalToSuperview()
}
}

Expand All @@ -42,4 +44,27 @@ class CreatorViewController: BaseViewController {
super.setCustomNavigationBar()
navigationItem.title = "만든 사람들"
}

override func viewDidLayoutSubviews() {
super.viewDidLayoutSubviews()
applyGradientBackground()
}

private func applyGradientBackground() {
if let existing = view.layer.sublayers?.first(where: { $0.name == "gradientLayer" }) {
existing.frame = view.bounds
return
}

let gradient = CAGradientLayer()
gradient.name = "gradientLayer"
gradient.frame = view.bounds
gradient.colors = [
EATSSUDesignAsset.Color.Gradation.highGradation.color.cgColor,
EATSSUDesignAsset.Color.Gradation.lowGradation.color.cgColor
]
gradient.startPoint = CGPoint(x: 0.5, y: 0.0)
gradient.endPoint = CGPoint(x: 0.5, y: 1.0)
view.layer.insertSublayer(gradient, at: 0)
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"info" : {
"author" : "xcode",
"version" : 1
},
"properties" : {
"provides-namespace" : true
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "255",
"green" : "228",
"red" : "184"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "227",
"green" : "255",
"red" : "199"
}
},
"idiom" : "universal"
}
],
"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.